File tree Expand file tree Collapse file tree
guides/postmark-error-handling Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -469,7 +469,7 @@ export default function ComparisonPage() {
469469 </ div >
470470 </ div >
471471
472- < EditPageLink path = "app/docs/comparison/page.tsx" />
472+ < EditPageLink />
473473 </ div >
474474 ) ;
475475}
Original file line number Diff line number Diff line change @@ -129,7 +129,7 @@ end`}</CodeBlock>
129129 < li > You send custom notifications based on error type</ li >
130130 </ ol >
131131
132- < EditPageLink path = "docs/app/docs/guides/postmark-error-handling/page.tsx" />
132+ < EditPageLink />
133133 </ div >
134134 ) ;
135135}
Original file line number Diff line number Diff line change @@ -158,7 +158,7 @@ variable "namespace" { type = string }`}
158158 </ ul >
159159 </ section >
160160
161- < EditPageLink path = "app/docs/terraform/page.tsx" />
161+ < EditPageLink />
162162 </ div >
163163 ) ;
164164}
Original file line number Diff line number Diff line change @@ -18,8 +18,8 @@ export function EditPageLink({ path }: EditPageLinkProps) {
1818 // Handle special case for root paths to avoid double slashes
1919 ( pathname === '/' ? '/docs/app/page.tsx' : `/docs/app${ pathname } /page.tsx` ) ;
2020
21- // Ensure there are no double slashes in the path
22- const normalizedPath = derivedPath . replace ( / \/ \/ / g, '/' ) ;
21+ // Ensure there are no double slashes in the path and path starts with /
22+ const normalizedPath = derivedPath . replace ( / \/ \/ / g, '/' ) . replace ( / ^ (? ! \/ ) / , '/' ) ;
2323
2424 const githubEditUrl = `https://github.com/DocSpring/logstruct/edit/main${ normalizedPath } ` ;
2525
You can’t perform that action at this time.
0 commit comments