File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -19,7 +19,6 @@ export class InternalLinkService {
1919 * Check if the provided link is internal, i.e., it starts with a '/' or matches the current URL.
2020 *
2121 * @param link The link to be checked.
22- * @param currentURL The current URL to compare against.
2322 * @returns A boolean indicating whether the link is internal.
2423 */
2524 public isLinkInternal ( link : string ) : boolean {
@@ -34,13 +33,12 @@ export class InternalLinkService {
3433 }
3534
3635 /**
37- * Transform an internal link based on the current URL.
36+ * Get the relative path for an internal link based on the current URL.
3837 *
39- * @param link The link to be transformed.
40- * @param currentURL The current URL used for transformation.
41- * @returns The transformed internal link.
38+ * @param link The internal link to be transformed.
39+ * @returns The relative path for the given internal link.
4240 */
43- public transformInternalLink ( link : string ) : string {
41+ public getRelativePath ( link : string ) : string {
4442 // Create a Domain object for the provided link
4543 const currentDomain = new URL ( this . currentURL ) . hostname ;
4644
You can’t perform that action at this time.
0 commit comments