Explorar o código

fix: xpath RegEx

Ahmad Kholid %!s(int64=2) %!d(string=hai) anos
pai
achega
f31d4563db
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/utils/helper.js

+ 1 - 1
src/utils/helper.js

@@ -1,7 +1,7 @@
 import browser from 'webextension-polyfill';
 
 export function isXPath(str) {
-  const regex = /^[(/@]/;
+  const regex = /^([(/@]|id\()/;
 
   return regex.test(str);
 }