Socket
Socket
Sign inDemoInstall

miolo-tools

Package Overview
Dependencies
9
Maintainers
1
Versions
50
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.0.41 to 0.0.42

6

dist/miolo-tools.cjs.js

@@ -107,5 +107,5 @@ 'use strict';

var CATCH_LOG_URL = '/sys/jserror';
var _DEF_CATCH_LOG_URL = '/sys/jserror';
function miolo_catcher_init() {
function miolo_catcher_init(catch_log_url) {
window.onerror = function (msg, file, line, col, error) {

@@ -125,3 +125,3 @@ try {

};
make_request('POST', CATCH_LOG_URL, params, false);
make_request('POST', catch_log_url || _DEF_CATCH_LOG_URL, params, false);
} catch (e) {

@@ -128,0 +128,0 @@ console.error(e);

@@ -1,1 +0,1 @@

"use strict";function t(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}Object.defineProperty(exports,"__esModule",{value:!0});var e=t(require("isomorphic-fetch"));function r(t,e){return t.replace(new RegExp("^".concat(e||"\\s","+")),"")}function n(t){return t.redirected?(window.location.replace(t.url),Promise.resolve()):t.headers.get("content-type").indexOf("json")>=0?t.json().then((e=>({data:e,status:t.status}))):t.text().then((e=>({data:e,status:t.status})))}function o(t,o,i,a,c){var s,u=(0==(s=o).indexOf("http")?s:process.env.BROWSER?"/"+r(s,"/"):"https://".concat(location.host,"/")+r(s,"/"))+("GET"===t&&i?function(t){return"?"+Object.keys(t).map((e=>{var r=encodeURIComponent(e);return Array.isArray(t[e])?t[e].map((t=>"".concat(r,"[]=").concat(encodeURIComponent(t)))).join("&"):"".concat(r,"=").concat(encodeURIComponent(t[e]))})).join("&")}(i):""),d={method:t,mode:"cors",credentials:"include",headers:{"content-type":"application/json"}};if(c&&(d.headers.Authorization="Basic "+Buffer.from(c.username+":"+c.password).toString("base64")),"POST"===t)if(a){var l=new FormData;for(var v in i)l.append(v,i[v]);d.body=l}else d.body=JSON.stringify(i||{},((t,e)=>void 0===e?null:e));return e.default(u,d).then(n)}function i(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function a(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?i(Object(r),!0).forEach((function(e){u(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function c(t,e,r,n,o,i,a){try{var c=t[i](a),s=c.value}catch(t){return void r(t)}c.done?e(s):Promise.resolve(s).then(n,o)}function s(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){c(i,n,o,a,s,"next",t)}function s(t){c(i,n,o,a,s,"throw",t)}a(void 0)}))}}function u(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var d={get(t,e){return o("GET",t,"object"!=typeof(r=e)?r:Object.keys(r).reduce(((t,e)=>(void 0!==r[e]&&(t[e]=r[e]),t)),{}));var r},post(t,e){return o("POST",t,e,arguments.length>2&&void 0!==arguments[2]&&arguments[2])}};class l{constructor(){u(this,"log_error",((t,e)=>{console.error(t),console.error(e)})),this.request=d}get(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{};try{return yield r.request.get(t,n)}catch(e){return r.log_error("Error on GET ".concat(t),e),{data:void 0,status:-1}}}))()}post(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{};try{return yield r.request.post(t,n)}catch(e){return r.log_error("Error on POST ".concat(t),e),{data:void 0,status:-1}}}))()}read(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{},o=e.length>2&&void 0!==e[2]?e[2]:{};return(yield r.get("".concat(t,"/read"),n,o)).data}))()}key_list(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{};return(yield n.get("".concat(t,"/key_list"),e,o)).data}))()}name_list(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{},i=yield n.key_list(t,e,o);return Object.values(i)}))()}find(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{};return(yield n.get("".concat(t,"/find"),{id:e},o)).data}))()}distinct(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>3&&void 0!==r[3]?r[3]:{},i=a(a({},r.length>2&&void 0!==r[2]?r[2]:{}),{},{distinct_field:e});return(yield n.get("".concat(t,"/distinct"),i,o)).data}))()}upsave(t,e){var r=arguments,n=this;return s((function*(){var o,i=r.length>2&&void 0!==r[2]?r[2]:{};return null==e.id?(delete e.id,o=yield n.post("".concat(t,"/save"),e,i)):o=yield n.post("".concat(t,"/update"),e,i),o.data}))()}remove(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{},i={id:e};return(yield n.post("".concat(t,"/delete"),i,o)).data}))()}}l.keyList=l.key_list,l.nameList=l.name_list,exports.Fetcher=l,exports.make_request=o,exports.miolo_catcher_init=function(){window.onerror=function(t,e,r,n,i){try{var a="UserAgent"+navigator.userAgent;o("POST","/sys/jserror",{error:{msg:t,file:e,line:r,col:n,error:i},path:window.location.pathname,agent:a},!1)}catch(t){console.error(t)}}};
"use strict";function t(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}Object.defineProperty(exports,"__esModule",{value:!0});var e=t(require("isomorphic-fetch"));function r(t,e){return t.replace(new RegExp("^".concat(e||"\\s","+")),"")}function n(t){return t.redirected?(window.location.replace(t.url),Promise.resolve()):t.headers.get("content-type").indexOf("json")>=0?t.json().then((e=>({data:e,status:t.status}))):t.text().then((e=>({data:e,status:t.status})))}function o(t,o,i,a,c){var s,u=(0==(s=o).indexOf("http")?s:process.env.BROWSER?"/"+r(s,"/"):"https://".concat(location.host,"/")+r(s,"/"))+("GET"===t&&i?function(t){return"?"+Object.keys(t).map((e=>{var r=encodeURIComponent(e);return Array.isArray(t[e])?t[e].map((t=>"".concat(r,"[]=").concat(encodeURIComponent(t)))).join("&"):"".concat(r,"=").concat(encodeURIComponent(t[e]))})).join("&")}(i):""),d={method:t,mode:"cors",credentials:"include",headers:{"content-type":"application/json"}};if(c&&(d.headers.Authorization="Basic "+Buffer.from(c.username+":"+c.password).toString("base64")),"POST"===t)if(a){var l=new FormData;for(var v in i)l.append(v,i[v]);d.body=l}else d.body=JSON.stringify(i||{},((t,e)=>void 0===e?null:e));return e.default(u,d).then(n)}function i(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function a(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?i(Object(r),!0).forEach((function(e){u(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function c(t,e,r,n,o,i,a){try{var c=t[i](a),s=c.value}catch(t){return void r(t)}c.done?e(s):Promise.resolve(s).then(n,o)}function s(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){c(i,n,o,a,s,"next",t)}function s(t){c(i,n,o,a,s,"throw",t)}a(void 0)}))}}function u(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var d={get(t,e){return o("GET",t,"object"!=typeof(r=e)?r:Object.keys(r).reduce(((t,e)=>(void 0!==r[e]&&(t[e]=r[e]),t)),{}));var r},post(t,e){return o("POST",t,e,arguments.length>2&&void 0!==arguments[2]&&arguments[2])}};class l{constructor(){u(this,"log_error",((t,e)=>{console.error(t),console.error(e)})),this.request=d}get(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{};try{return yield r.request.get(t,n)}catch(e){return r.log_error("Error on GET ".concat(t),e),{data:void 0,status:-1}}}))()}post(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{};try{return yield r.request.post(t,n)}catch(e){return r.log_error("Error on POST ".concat(t),e),{data:void 0,status:-1}}}))()}read(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{},o=e.length>2&&void 0!==e[2]?e[2]:{};return(yield r.get("".concat(t,"/read"),n,o)).data}))()}key_list(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{};return(yield n.get("".concat(t,"/key_list"),e,o)).data}))()}name_list(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{},i=yield n.key_list(t,e,o);return Object.values(i)}))()}find(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{};return(yield n.get("".concat(t,"/find"),{id:e},o)).data}))()}distinct(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>3&&void 0!==r[3]?r[3]:{},i=a(a({},r.length>2&&void 0!==r[2]?r[2]:{}),{},{distinct_field:e});return(yield n.get("".concat(t,"/distinct"),i,o)).data}))()}upsave(t,e){var r=arguments,n=this;return s((function*(){var o,i=r.length>2&&void 0!==r[2]?r[2]:{};return null==e.id?(delete e.id,o=yield n.post("".concat(t,"/save"),e,i)):o=yield n.post("".concat(t,"/update"),e,i),o.data}))()}remove(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{},i={id:e};return(yield n.post("".concat(t,"/delete"),i,o)).data}))()}}l.keyList=l.key_list,l.nameList=l.name_list,exports.Fetcher=l,exports.make_request=o,exports.miolo_catcher_init=function(t){window.onerror=function(e,r,n,i,a){try{var c="UserAgent"+navigator.userAgent,s={error:{msg:e,file:r,line:n,col:i,error:a},path:window.location.pathname,agent:c};o("POST",t||"/sys/jserror",s,!1)}catch(t){console.error(t)}}};

@@ -99,5 +99,5 @@ import fetch from 'isomorphic-fetch';

var CATCH_LOG_URL = '/sys/jserror';
var _DEF_CATCH_LOG_URL = '/sys/jserror';
function miolo_catcher_init() {
function miolo_catcher_init(catch_log_url) {
window.onerror = function (msg, file, line, col, error) {

@@ -117,3 +117,3 @@ try {

};
make_request('POST', CATCH_LOG_URL, params, false);
make_request('POST', catch_log_url || _DEF_CATCH_LOG_URL, params, false);
} catch (e) {

@@ -120,0 +120,0 @@ console.error(e);

@@ -1,1 +0,1 @@

import t from"isomorphic-fetch";function e(t,e){return t.replace(new RegExp("^".concat(e||"\\s","+")),"")}function r(t){return t.redirected?(window.location.replace(t.url),Promise.resolve()):t.headers.get("content-type").indexOf("json")>=0?t.json().then((e=>({data:e,status:t.status}))):t.text().then((e=>({data:e,status:t.status})))}function n(n,o,i,a,c){var s,u=(0==(s=o).indexOf("http")?s:process.env.BROWSER?"/"+e(s,"/"):"https://".concat(location.host,"/")+e(s,"/"))+("GET"===n&&i?function(t){return"?"+Object.keys(t).map((e=>{var r=encodeURIComponent(e);return Array.isArray(t[e])?t[e].map((t=>"".concat(r,"[]=").concat(encodeURIComponent(t)))).join("&"):"".concat(r,"=").concat(encodeURIComponent(t[e]))})).join("&")}(i):""),d={method:n,mode:"cors",credentials:"include",headers:{"content-type":"application/json"}};if(c&&(d.headers.Authorization="Basic "+Buffer.from(c.username+":"+c.password).toString("base64")),"POST"===n)if(a){var l=new FormData;for(var v in i)l.append(v,i[v]);d.body=l}else d.body=JSON.stringify(i||{},((t,e)=>void 0===e?null:e));return t(u,d).then(r)}function o(){window.onerror=function(t,e,r,o,i){try{var a="UserAgent"+navigator.userAgent;n("POST","/sys/jserror",{error:{msg:t,file:e,line:r,col:o,error:i},path:window.location.pathname,agent:a},!1)}catch(t){console.error(t)}}}function i(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function a(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?i(Object(r),!0).forEach((function(e){u(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function c(t,e,r,n,o,i,a){try{var c=t[i](a),s=c.value}catch(t){return void r(t)}c.done?e(s):Promise.resolve(s).then(n,o)}function s(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){c(i,n,o,a,s,"next",t)}function s(t){c(i,n,o,a,s,"throw",t)}a(void 0)}))}}function u(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var d={get(t,e){return n("GET",t,"object"!=typeof(r=e)?r:Object.keys(r).reduce(((t,e)=>(void 0!==r[e]&&(t[e]=r[e]),t)),{}));var r},post(t,e){return n("POST",t,e,arguments.length>2&&void 0!==arguments[2]&&arguments[2])}};class l{constructor(){u(this,"log_error",((t,e)=>{console.error(t),console.error(e)})),this.request=d}get(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{};try{return yield r.request.get(t,n)}catch(e){return r.log_error("Error on GET ".concat(t),e),{data:void 0,status:-1}}}))()}post(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{};try{return yield r.request.post(t,n)}catch(e){return r.log_error("Error on POST ".concat(t),e),{data:void 0,status:-1}}}))()}read(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{},o=e.length>2&&void 0!==e[2]?e[2]:{};return(yield r.get("".concat(t,"/read"),n,o)).data}))()}key_list(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{};return(yield n.get("".concat(t,"/key_list"),e,o)).data}))()}name_list(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{},i=yield n.key_list(t,e,o);return Object.values(i)}))()}find(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{};return(yield n.get("".concat(t,"/find"),{id:e},o)).data}))()}distinct(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>3&&void 0!==r[3]?r[3]:{},i=a(a({},r.length>2&&void 0!==r[2]?r[2]:{}),{},{distinct_field:e});return(yield n.get("".concat(t,"/distinct"),i,o)).data}))()}upsave(t,e){var r=arguments,n=this;return s((function*(){var o,i=r.length>2&&void 0!==r[2]?r[2]:{};return null==e.id?(delete e.id,o=yield n.post("".concat(t,"/save"),e,i)):o=yield n.post("".concat(t,"/update"),e,i),o.data}))()}remove(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{},i={id:e};return(yield n.post("".concat(t,"/delete"),i,o)).data}))()}}l.keyList=l.key_list,l.nameList=l.name_list;export{l as Fetcher,n as make_request,o as miolo_catcher_init};
import t from"isomorphic-fetch";function e(t,e){return t.replace(new RegExp("^".concat(e||"\\s","+")),"")}function r(t){return t.redirected?(window.location.replace(t.url),Promise.resolve()):t.headers.get("content-type").indexOf("json")>=0?t.json().then((e=>({data:e,status:t.status}))):t.text().then((e=>({data:e,status:t.status})))}function n(n,o,i,a,c){var s,u=(0==(s=o).indexOf("http")?s:process.env.BROWSER?"/"+e(s,"/"):"https://".concat(location.host,"/")+e(s,"/"))+("GET"===n&&i?function(t){return"?"+Object.keys(t).map((e=>{var r=encodeURIComponent(e);return Array.isArray(t[e])?t[e].map((t=>"".concat(r,"[]=").concat(encodeURIComponent(t)))).join("&"):"".concat(r,"=").concat(encodeURIComponent(t[e]))})).join("&")}(i):""),d={method:n,mode:"cors",credentials:"include",headers:{"content-type":"application/json"}};if(c&&(d.headers.Authorization="Basic "+Buffer.from(c.username+":"+c.password).toString("base64")),"POST"===n)if(a){var l=new FormData;for(var v in i)l.append(v,i[v]);d.body=l}else d.body=JSON.stringify(i||{},((t,e)=>void 0===e?null:e));return t(u,d).then(r)}function o(t){window.onerror=function(e,r,o,i,a){try{var c="UserAgent"+navigator.userAgent,s={error:{msg:e,file:r,line:o,col:i,error:a},path:window.location.pathname,agent:c};n("POST",t||"/sys/jserror",s,!1)}catch(t){console.error(t)}}}function i(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function a(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?i(Object(r),!0).forEach((function(e){u(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function c(t,e,r,n,o,i,a){try{var c=t[i](a),s=c.value}catch(t){return void r(t)}c.done?e(s):Promise.resolve(s).then(n,o)}function s(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var i=t.apply(e,r);function a(t){c(i,n,o,a,s,"next",t)}function s(t){c(i,n,o,a,s,"throw",t)}a(void 0)}))}}function u(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var d={get(t,e){return n("GET",t,"object"!=typeof(r=e)?r:Object.keys(r).reduce(((t,e)=>(void 0!==r[e]&&(t[e]=r[e]),t)),{}));var r},post(t,e){return n("POST",t,e,arguments.length>2&&void 0!==arguments[2]&&arguments[2])}};class l{constructor(){u(this,"log_error",((t,e)=>{console.error(t),console.error(e)})),this.request=d}get(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{};try{return yield r.request.get(t,n)}catch(e){return r.log_error("Error on GET ".concat(t),e),{data:void 0,status:-1}}}))()}post(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{};try{return yield r.request.post(t,n)}catch(e){return r.log_error("Error on POST ".concat(t),e),{data:void 0,status:-1}}}))()}read(t){var e=arguments,r=this;return s((function*(){var n=e.length>1&&void 0!==e[1]?e[1]:{},o=e.length>2&&void 0!==e[2]?e[2]:{};return(yield r.get("".concat(t,"/read"),n,o)).data}))()}key_list(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{};return(yield n.get("".concat(t,"/key_list"),e,o)).data}))()}name_list(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{},i=yield n.key_list(t,e,o);return Object.values(i)}))()}find(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{};return(yield n.get("".concat(t,"/find"),{id:e},o)).data}))()}distinct(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>3&&void 0!==r[3]?r[3]:{},i=a(a({},r.length>2&&void 0!==r[2]?r[2]:{}),{},{distinct_field:e});return(yield n.get("".concat(t,"/distinct"),i,o)).data}))()}upsave(t,e){var r=arguments,n=this;return s((function*(){var o,i=r.length>2&&void 0!==r[2]?r[2]:{};return null==e.id?(delete e.id,o=yield n.post("".concat(t,"/save"),e,i)):o=yield n.post("".concat(t,"/update"),e,i),o.data}))()}remove(t,e){var r=arguments,n=this;return s((function*(){var o=r.length>2&&void 0!==r[2]?r[2]:{},i={id:e};return(yield n.post("".concat(t,"/delete"),i,o)).data}))()}}l.keyList=l.key_list,l.nameList=l.name_list;export{l as Fetcher,n as make_request,o as miolo_catcher_init};

@@ -107,5 +107,5 @@ (function (global, factory) {

var CATCH_LOG_URL = '/sys/jserror';
var _DEF_CATCH_LOG_URL = '/sys/jserror';
function miolo_catcher_init() {
function miolo_catcher_init(catch_log_url) {
window.onerror = function (msg, file, line, col, error) {

@@ -125,3 +125,3 @@ try {

};
make_request('POST', CATCH_LOG_URL, params, false);
make_request('POST', catch_log_url || _DEF_CATCH_LOG_URL, params, false);
} catch (e) {

@@ -128,0 +128,0 @@ console.error(e);

@@ -107,5 +107,5 @@ (function (global, factory) {

var CATCH_LOG_URL = '/sys/jserror';
var _DEF_CATCH_LOG_URL = '/sys/jserror';
function miolo_catcher_init() {
function miolo_catcher_init(catch_log_url) {
window.onerror = function (msg, file, line, col, error) {

@@ -125,3 +125,3 @@ try {

};
make_request('POST', CATCH_LOG_URL, params, false);
make_request('POST', catch_log_url || _DEF_CATCH_LOG_URL, params, false);
} catch (e) {

@@ -128,0 +128,0 @@ console.error(e);

@@ -10,5 +10,5 @@ "use strict";

var CATCH_LOG_URL = '/sys/jserror';
var _DEF_CATCH_LOG_URL = '/sys/jserror';
function miolo_catcher_init() {
function miolo_catcher_init(catch_log_url) {
window.onerror = function (msg, file, line, col, error) {

@@ -28,3 +28,3 @@ try {

};
(0, _request.make_request)('POST', CATCH_LOG_URL, params, false);
(0, _request.make_request)('POST', catch_log_url || _DEF_CATCH_LOG_URL, params, false);
} catch (e) {

@@ -31,0 +31,0 @@ console.error(e);

{
"name": "miolo-tools",
"version": "0.0.41",
"version": "0.0.42",
"description": "cli tools for miolo",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

import {make_request} from '../request'
const CATCH_LOG_URL= '/sys/jserror'
const _DEF_CATCH_LOG_URL= '/sys/jserror'
function miolo_catcher_init () {
function miolo_catcher_init (catch_log_url) {

@@ -18,3 +18,3 @@ window.onerror = function(msg, file, line, col, error) {

make_request('POST', CATCH_LOG_URL, params, false)
make_request('POST', catch_log_url || _DEF_CATCH_LOG_URL, params, false)

@@ -21,0 +21,0 @@ } catch(e) {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc