HEX
Server: Apache/2.4.41 (Ubuntu)
System: Linux wordpress-ubuntu-s-2vcpu-4gb-fra1-01 5.4.0-169-generic #187-Ubuntu SMP Thu Nov 23 14:52:28 UTC 2023 x86_64
User: root (0)
PHP: 7.4.33
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: //proc/1526/task/1529/cwd/tana/frontend/node_modules/locutus/golang/strings/Count.js.map
{"version":3,"sources":["../../../src/golang/strings/Count.js"],"names":["module","exports","Count","s","sep","pos","n","length","split","indexOf","substring"],"mappings":";;AAAAA,OAAOC,OAAP,GAAiB,SAASC,KAAT,CAAgBC,CAAhB,EAAmBC,GAAnB,EAAwB;AACvC;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,MAAIC,GAAJ;AACA,MAAIC,IAAI,CAAR;;AAEA,MAAKF,IAAIG,MAAJ,KAAe,CAApB,EAAwB;AACtB,WAAOJ,EAAEK,KAAF,CAAQJ,GAAR,EAAaG,MAAb,GAAsB,CAA7B;AACD,GAFD,MAEO,IAAIH,IAAIG,MAAJ,GAAaJ,EAAEI,MAAnB,EAA2B;AAChC,WAAO,CAAP;AACD,GAFM,MAEA,IAAKH,IAAIG,MAAJ,KAAeJ,EAAEI,MAAtB,EAA+B;AACpC,QAAIH,QAAQD,CAAZ,EAAe;AACb,aAAO,CAAP;AACD;AACD,WAAO,CAAP;AACD;AACD,SAAO,IAAP,EAAa;AACXE,UAAM,CAACF,IAAI,EAAL,EAASM,OAAT,CAAiBL,GAAjB,CAAN;AACA,QAAIC,QAAQ,CAAC,CAAb,EAAgB;AACd;AACD;AACDC,QAAIA,IAAK,CAAL,IAAW,CAAf;AACAH,QAAIA,EAAEO,SAAF,CAAaL,MAAMD,IAAIG,MAAV,IAAoB,CAAjC,CAAJ;AACD;AACD,SAAOD,CAAP;AACD,CA/BD","file":"Count.js","sourcesContent":["module.exports = function Count (s, sep) {\n  //  discuss at: http://locutus.io/php/printf/\n  // original by: Kevin van Zonneveld (http://kvz.io)\n  //    input by: GopherJS (http://www.gopherjs.org/)\n  //   example 1: Count(\"cheese\", \"e\")\n  //   returns 1: 3\n  //   example 2: Count(\"five\", \"\") // before & after each rune\n  //   returns 2: 5\n\n  var pos\n  var n = 0\n\n  if ((sep.length === 0)) {\n    return s.split(sep).length + 1\n  } else if (sep.length > s.length) {\n    return 0\n  } else if ((sep.length === s.length)) {\n    if (sep === s) {\n      return 1\n    }\n    return 0\n  }\n  while (true) {\n    pos = (s + '').indexOf(sep)\n    if (pos === -1) {\n      break\n    }\n    n = n + (1) >> 0\n    s = s.substring((pos + sep.length >> 0))\n  }\n  return n\n}\n"]}