소스 검색

fix/change validate method and update regular expression

keigo-h 4 년 전
부모
커밋
1c0c1cf4a8
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      packages/app/src/client/services/ShowPageAccessories.tsx

+ 1 - 1
packages/app/src/client/services/ShowPageAccessories.tsx

@@ -13,7 +13,7 @@ const ShowPageAccessoriesModal = (): JSX.Element => {
   useEffect(() => {
     const pageIdParams = getURLQueryParamValue('compare');
     if (pageIdParams != null) {
-      if (pageIdParams.search(/.{24}\.{3}.{24}/) !== -1) {
+      if (/([a-z]|[0-9]){24}\.{3}([a-z]|[0-9]){24}/.test(pageIdParams)) {
         openPageAccessories(PageAccessoriesModalContents.PageHistory);
       }
     }