Explorar o código

Merge pull request #7268 from weseek/fix/113678-refactor-uri-decode

fix: Refactor uri decoding in getServerSideProps
Yuki Takei %!s(int64=3) %!d(string=hai) anos
pai
achega
5160dc70e5
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      packages/app/src/pages/utils/commons.ts

+ 1 - 1
packages/app/src/pages/utils/commons.ts

@@ -36,7 +36,7 @@ export const getServerSideCommonProps: GetServerSideProps<CommonProps> = async(c
   } = crowi;
 
   const url = new URL(context.resolvedUrl, 'http://example.com');
-  const currentPathname = decodeURI(url.pathname);
+  const currentPathname = decodeURIComponent(url.pathname);
 
   const isMaintenanceMode = appService.isMaintenanceMode();