New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

ryuu.js

Package Overview
Dependencies
Maintainers
4
Versions
54
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ryuu.js - npm Package Compare versions

Comparing version 2.5.9 to 2.5.10

4

dist/domo.js

@@ -5,3 +5,3 @@ /*!

*/
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.domo=e():t.domo=e()}(this,function(){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return t[r].call(o.exports,o,o.exports,e),o.loaded=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="/dist/",e(0)}([function(t,e,n){"use strict";function r(){}function o(){var t=location.search.substr(1),e={};return t.split("&").forEach(function(t){var n=t.split("=");e[n[0]]=decodeURIComponent(n[1])}),e}function i(t,e,n){e.indexOf("data/v1")!==-1&&("array-of-arrays"===n.format?t.setRequestHeader("Accept","application/json"):"csv"===n.format?t.setRequestHeader("Accept","text/csv"):"excel"===n.format?t.setRequestHeader("Accept","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"):t.setRequestHeader("Accept","application/array-of-objects"))}n(1).polyfill(),t.exports=r,r.get=function(t,e){return e=e||{},new Promise(function(n,r){var o=new XMLHttpRequest;o.open("GET",t),i(o,t,e),o.onload=function(){var t;if(200==o.status){"csv"!==e.format&&"excel"!==e.format||n(o.response);try{t=JSON.parse(o.response)}catch(t){return void r(Error("Invalid JSON response"))}n(t)}else r(Error(o.statusText))},o.onerror=function(){r(Error("Network Error"))},o.send()})},r.getAll=function(t,e){return Promise.all(t.map(function(t){return r.get(t,e)}))},r.onDataUpdate=function(t){window.addEventListener("message",function(e){if("string"==typeof e.data)try{var n=JSON.parse(e.data);if(!n.hasOwnProperty("alias"))return;var r=n.alias,o=JSON.stringify({event:"ack",alias:r});e.source.postMessage(o,e.origin),t(r)}catch(t){var i="There was an error in domo.onDataUpdate! It may be that our event listener caught a message from another source and tried to parse it, so your update still may have worked. If you would like more info, here is the error: \n";console.warn(i,t)}})},r.navigate=function(t,e){var n=JSON.stringify({event:"navigate",url:t,isNewWindow:e});window.parent.postMessage(n,"*")},r.env=o()},function(t,e,n){(function(e,r){/*!
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.domo=e():t.domo=e()}(this,function(){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return t[r].call(o.exports,o,o.exports,e),o.loaded=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="/dist/",e(0)}([function(t,e,n){"use strict";function r(){}function o(t){var e=t.match("^https?://([^/]+[.])?(domo|domotech|domorig).(com|io)?(/.*)?$"),n=t.match("(.*).(domoapps).(.*)");return!!e&&!n}function i(){var t=location.search.substr(1),e={};return t.split("&").forEach(function(t){var n=t.split("=");e[n[0]]=decodeURIComponent(n[1])}),e}function s(t,e,n){e.indexOf("data/v1")!==-1&&("array-of-arrays"===n.format?t.setRequestHeader("Accept","application/json"):"csv"===n.format?t.setRequestHeader("Accept","text/csv"):"excel"===n.format?t.setRequestHeader("Accept","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"):t.setRequestHeader("Accept","application/array-of-objects"))}n(1).polyfill(),t.exports=r,r.get=function(t,e){return e=e||{},new Promise(function(n,r){var o=new XMLHttpRequest;o.open("GET",t),s(o,t,e),o.onload=function(){var t;if(200==o.status){"csv"!==e.format&&"excel"!==e.format||n(o.response);try{t=JSON.parse(o.response)}catch(t){return void r(Error("Invalid JSON response"))}n(t)}else r(Error(o.statusText))},o.onerror=function(){r(Error("Network Error"))},o.send()})},r.getAll=function(t,e){return Promise.all(t.map(function(t){return r.get(t,e)}))},r.onDataUpdate=function(t){window.addEventListener("message",function(e){if(o(e.origin)&&"string"==typeof e.data)try{var n=JSON.parse(e.data);if(!n.hasOwnProperty("alias"))return;var r=n.alias,i=JSON.stringify({event:"ack",alias:r});e.source.postMessage(i,e.origin),t(r)}catch(t){var s="There was an error in domo.onDataUpdate! It may be that our event listener caught a message from another source and tried to parse it, so your update still may have worked. If you would like more info, here is the error: \n";console.warn(s,t)}})},r.navigate=function(t,e){var n=JSON.stringify({event:"navigate",url:t,isNewWindow:e});window.parent.postMessage(n,"*")},r.env=i(),r.__util={isVerifiedOrigin:o,getQueryParams:i,setFormatHeaders:s}},function(t,e,n){(function(e,r){/*!
* @overview es6-promise - a tiny implementation of Promises/A+.

@@ -13,3 +13,3 @@ * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)

*/
!function(e,n){t.exports=n()}(this,function(){"use strict";function t(t){return"function"==typeof t||"object"==typeof t&&null!==t}function o(t){return"function"==typeof t}function i(t){B=t}function s(t){Q=t}function u(){return function(){return e.nextTick(h)}}function c(){return function(){z(h)}}function a(){var t=0,e=new $(h),n=document.createTextNode("");return e.observe(n,{characterData:!0}),function(){n.data=t=++t%2}}function f(){var t=new MessageChannel;return t.port1.onmessage=h,function(){return t.port2.postMessage(0)}}function l(){var t=setTimeout;return function(){return t(h,1)}}function h(){for(var t=0;t<X;t+=2){var e=nt[t],n=nt[t+1];e(n),nt[t]=void 0,nt[t+1]=void 0}X=0}function p(){try{var t=n(3);return z=t.runOnLoop||t.runOnContext,c()}catch(t){return l()}}function d(t,e){var n=arguments,r=this,o=new this.constructor(m);void 0===o[ot]&&R(o);var i=r._state;return i?!function(){var t=n[i-1];Q(function(){return L(i,o,t,r._result)})}():O(r,o,t,e),o}function v(t){var e=this;if(t&&"object"==typeof t&&t.constructor===e)return t;var n=new e(m);return x(n,t),n}function m(){}function y(){return new TypeError("You cannot resolve a promise with itself")}function _(){return new TypeError("A promises callback cannot return that same promise.")}function w(t){try{return t.then}catch(t){return ct.error=t,ct}}function g(t,e,n,r){try{t.call(e,n,r)}catch(t){return t}}function b(t,e,n){Q(function(t){var r=!1,o=g(n,e,function(n){r||(r=!0,e!==n?x(t,n):S(t,n))},function(e){r||(r=!0,j(t,e))},"Settle: "+(t._label||" unknown promise"));!r&&o&&(r=!0,j(t,o))},t)}function T(t,e){e._state===st?S(t,e._result):e._state===ut?j(t,e._result):O(e,void 0,function(e){return x(t,e)},function(e){return j(t,e)})}function A(t,e,n){e.constructor===t.constructor&&n===d&&e.constructor.resolve===v?T(t,e):n===ct?j(t,ct.error):void 0===n?S(t,e):o(n)?b(t,e,n):S(t,e)}function x(e,n){e===n?j(e,y()):t(n)?A(e,n,w(n)):S(e,n)}function E(t){t._onerror&&t._onerror(t._result),M(t)}function S(t,e){t._state===it&&(t._result=e,t._state=st,0!==t._subscribers.length&&Q(M,t))}function j(t,e){t._state===it&&(t._state=ut,t._result=e,Q(E,t))}function O(t,e,n,r){var o=t._subscribers,i=o.length;t._onerror=null,o[i]=e,o[i+st]=n,o[i+ut]=r,0===i&&t._state&&Q(M,t)}function M(t){var e=t._subscribers,n=t._state;if(0!==e.length){for(var r=void 0,o=void 0,i=t._result,s=0;s<e.length;s+=3)r=e[s],o=e[s+n],r?L(n,r,o,i):o(i);t._subscribers.length=0}}function k(){this.error=null}function P(t,e){try{return t(e)}catch(t){return at.error=t,at}}function L(t,e,n,r){var i=o(n),s=void 0,u=void 0,c=void 0,a=void 0;if(i){if(s=P(n,r),s===at?(a=!0,u=s.error,s=null):c=!0,e===s)return void j(e,_())}else s=r,c=!0;e._state!==it||(i&&c?x(e,s):a?j(e,u):t===st?S(e,s):t===ut&&j(e,s))}function N(t,e){try{e(function(e){x(t,e)},function(e){j(t,e)})}catch(e){j(t,e)}}function C(){return ft++}function R(t){t[ot]=ft++,t._state=void 0,t._result=void 0,t._subscribers=[]}function q(t,e){this._instanceConstructor=t,this.promise=new t(m),this.promise[ot]||R(this.promise),K(e)?(this._input=e,this.length=e.length,this._remaining=e.length,this._result=new Array(this.length),0===this.length?S(this.promise,this._result):(this.length=this.length||0,this._enumerate(),0===this._remaining&&S(this.promise,this._result))):j(this.promise,H())}function H(){return new Error("Array Methods must be provided an Array")}function J(t){return new q(this,t).promise}function I(t){var e=this;return new e(K(t)?function(n,r){for(var o=t.length,i=0;i<o;i++)e.resolve(t[i]).then(n,r)}:function(t,e){return e(new TypeError("You must pass an array to race."))})}function U(t){var e=this,n=new e(m);return j(n,t),n}function D(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}function Y(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}function F(t){this[ot]=C(),this._result=this._state=void 0,this._subscribers=[],m!==t&&("function"!=typeof t&&D(),this instanceof F?N(this,t):Y())}function W(){var t=void 0;if("undefined"!=typeof r)t=r;else if("undefined"!=typeof self)t=self;else try{t=Function("return this")()}catch(t){throw new Error("polyfill failed because global object is unavailable in this environment")}var e=t.Promise;if(e){var n=null;try{n=Object.prototype.toString.call(e.resolve())}catch(t){}if("[object Promise]"===n&&!e.cast)return}t.Promise=F}var G=void 0;G=Array.isArray?Array.isArray:function(t){return"[object Array]"===Object.prototype.toString.call(t)};var K=G,X=0,z=void 0,B=void 0,Q=function(t,e){nt[X]=t,nt[X+1]=e,X+=2,2===X&&(B?B(h):rt())},V="undefined"!=typeof window?window:void 0,Z=V||{},$=Z.MutationObserver||Z.WebKitMutationObserver,tt="undefined"==typeof self&&"undefined"!=typeof e&&"[object process]"==={}.toString.call(e),et="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel,nt=new Array(1e3),rt=void 0;rt=tt?u():$?a():et?f():void 0===V?p():l();var ot=Math.random().toString(36).substring(16),it=void 0,st=1,ut=2,ct=new k,at=new k,ft=0;return q.prototype._enumerate=function(){for(var t=this.length,e=this._input,n=0;this._state===it&&n<t;n++)this._eachEntry(e[n],n)},q.prototype._eachEntry=function(t,e){var n=this._instanceConstructor,r=n.resolve;if(r===v){var o=w(t);if(o===d&&t._state!==it)this._settledAt(t._state,e,t._result);else if("function"!=typeof o)this._remaining--,this._result[e]=t;else if(n===F){var i=new n(m);A(i,t,o),this._willSettleAt(i,e)}else this._willSettleAt(new n(function(e){return e(t)}),e)}else this._willSettleAt(r(t),e)},q.prototype._settledAt=function(t,e,n){var r=this.promise;r._state===it&&(this._remaining--,t===ut?j(r,n):this._result[e]=n),0===this._remaining&&S(r,this._result)},q.prototype._willSettleAt=function(t,e){var n=this;O(t,void 0,function(t){return n._settledAt(st,e,t)},function(t){return n._settledAt(ut,e,t)})},F.all=J,F.race=I,F.resolve=v,F.reject=U,F._setScheduler=i,F._setAsap=s,F._asap=Q,F.prototype={constructor:F,then:d,catch:function(t){return this.then(null,t)}},W(),F.polyfill=W,F.Promise=F,F})}).call(e,n(2),function(){return this}())},function(t,e){function n(){throw new Error("setTimeout has not been defined")}function r(){throw new Error("clearTimeout has not been defined")}function o(t){if(f===setTimeout)return setTimeout(t,0);if((f===n||!f)&&setTimeout)return f=setTimeout,setTimeout(t,0);try{return f(t,0)}catch(e){try{return f.call(null,t,0)}catch(e){return f.call(this,t,0)}}}function i(t){if(l===clearTimeout)return clearTimeout(t);if((l===r||!l)&&clearTimeout)return l=clearTimeout,clearTimeout(t);try{return l(t)}catch(e){try{return l.call(null,t)}catch(e){return l.call(this,t)}}}function s(){v&&p&&(v=!1,p.length?d=p.concat(d):m=-1,d.length&&u())}function u(){if(!v){var t=o(s);v=!0;for(var e=d.length;e;){for(p=d,d=[];++m<e;)p&&p[m].run();m=-1,e=d.length}p=null,v=!1,i(t)}}function c(t,e){this.fun=t,this.array=e}function a(){}var f,l,h=t.exports={};!function(){try{f="function"==typeof setTimeout?setTimeout:n}catch(t){f=n}try{l="function"==typeof clearTimeout?clearTimeout:r}catch(t){l=r}}();var p,d=[],v=!1,m=-1;h.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];d.push(new c(t,e)),1!==d.length||v||o(u)},c.prototype.run=function(){this.fun.apply(null,this.array)},h.title="browser",h.browser=!0,h.env={},h.argv=[],h.version="",h.versions={},h.on=a,h.addListener=a,h.once=a,h.off=a,h.removeListener=a,h.removeAllListeners=a,h.emit=a,h.prependListener=a,h.prependOnceListener=a,h.listeners=function(t){return[]},h.binding=function(t){throw new Error("process.binding is not supported")},h.cwd=function(){return"/"},h.chdir=function(t){throw new Error("process.chdir is not supported")},h.umask=function(){return 0}},function(t,e){}])});
!function(e,n){t.exports=n()}(this,function(){"use strict";function t(t){return"function"==typeof t||"object"==typeof t&&null!==t}function o(t){return"function"==typeof t}function i(t){X=t}function s(t){$=t}function u(){return function(){return e.nextTick(h)}}function c(){return function(){V(h)}}function a(){var t=0,e=new Z(h),n=document.createTextNode("");return e.observe(n,{characterData:!0}),function(){n.data=t=++t%2}}function f(){var t=new MessageChannel;return t.port1.onmessage=h,function(){return t.port2.postMessage(0)}}function l(){var t=setTimeout;return function(){return t(h,1)}}function h(){for(var t=0;t<Q;t+=2){var e=nt[t],n=nt[t+1];e(n),nt[t]=void 0,nt[t+1]=void 0}Q=0}function p(){try{var t=n(3);return V=t.runOnLoop||t.runOnContext,c()}catch(t){return l()}}function d(t,e){var n=arguments,r=this,o=new this.constructor(m);void 0===o[ot]&&H(o);var i=r._state;return i?!function(){var t=n[i-1];$(function(){return L(i,o,t,r._result)})}():O(r,o,t,e),o}function v(t){var e=this;if(t&&"object"==typeof t&&t.constructor===e)return t;var n=new e(m);return x(n,t),n}function m(){}function y(){return new TypeError("You cannot resolve a promise with itself")}function _(){return new TypeError("A promises callback cannot return that same promise.")}function w(t){try{return t.then}catch(t){return ct.error=t,ct}}function g(t,e,n,r){try{t.call(e,n,r)}catch(t){return t}}function b(t,e,n){$(function(t){var r=!1,o=g(n,e,function(n){r||(r=!0,e!==n?x(t,n):S(t,n))},function(e){r||(r=!0,j(t,e))},"Settle: "+(t._label||" unknown promise"));!r&&o&&(r=!0,j(t,o))},t)}function T(t,e){e._state===st?S(t,e._result):e._state===ut?j(t,e._result):O(e,void 0,function(e){return x(t,e)},function(e){return j(t,e)})}function A(t,e,n){e.constructor===t.constructor&&n===d&&e.constructor.resolve===v?T(t,e):n===ct?j(t,ct.error):void 0===n?S(t,e):o(n)?b(t,e,n):S(t,e)}function x(e,n){e===n?j(e,y()):t(n)?A(e,n,w(n)):S(e,n)}function E(t){t._onerror&&t._onerror(t._result),M(t)}function S(t,e){t._state===it&&(t._result=e,t._state=st,0!==t._subscribers.length&&$(M,t))}function j(t,e){t._state===it&&(t._state=ut,t._result=e,$(E,t))}function O(t,e,n,r){var o=t._subscribers,i=o.length;t._onerror=null,o[i]=e,o[i+st]=n,o[i+ut]=r,0===i&&t._state&&$(M,t)}function M(t){var e=t._subscribers,n=t._state;if(0!==e.length){for(var r=void 0,o=void 0,i=t._result,s=0;s<e.length;s+=3)r=e[s],o=e[s+n],r?L(n,r,o,i):o(i);t._subscribers.length=0}}function P(){this.error=null}function k(t,e){try{return t(e)}catch(t){return at.error=t,at}}function L(t,e,n,r){var i=o(n),s=void 0,u=void 0,c=void 0,a=void 0;if(i){if(s=k(n,r),s===at?(a=!0,u=s.error,s=null):c=!0,e===s)return void j(e,_())}else s=r,c=!0;e._state!==it||(i&&c?x(e,s):a?j(e,u):t===st?S(e,s):t===ut&&j(e,s))}function N(t,e){try{e(function(e){x(t,e)},function(e){j(t,e)})}catch(e){j(t,e)}}function C(){return ft++}function H(t){t[ot]=ft++,t._state=void 0,t._result=void 0,t._subscribers=[]}function R(t,e){this._instanceConstructor=t,this.promise=new t(m),this.promise[ot]||H(this.promise),K(e)?(this._input=e,this.length=e.length,this._remaining=e.length,this._result=new Array(this.length),0===this.length?S(this.promise,this._result):(this.length=this.length||0,this._enumerate(),0===this._remaining&&S(this.promise,this._result))):j(this.promise,q())}function q(){return new Error("Array Methods must be provided an Array")}function J(t){return new R(this,t).promise}function I(t){var e=this;return new e(K(t)?function(n,r){for(var o=t.length,i=0;i<o;i++)e.resolve(t[i]).then(n,r)}:function(t,e){return e(new TypeError("You must pass an array to race."))})}function U(t){var e=this,n=new e(m);return j(n,t),n}function D(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}function F(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}function Y(t){this[ot]=C(),this._result=this._state=void 0,this._subscribers=[],m!==t&&("function"!=typeof t&&D(),this instanceof Y?N(this,t):F())}function W(){var t=void 0;if("undefined"!=typeof r)t=r;else if("undefined"!=typeof self)t=self;else try{t=Function("return this")()}catch(t){throw new Error("polyfill failed because global object is unavailable in this environment")}var e=t.Promise;if(e){var n=null;try{n=Object.prototype.toString.call(e.resolve())}catch(t){}if("[object Promise]"===n&&!e.cast)return}t.Promise=Y}var G=void 0;G=Array.isArray?Array.isArray:function(t){return"[object Array]"===Object.prototype.toString.call(t)};var K=G,Q=0,V=void 0,X=void 0,$=function(t,e){nt[Q]=t,nt[Q+1]=e,Q+=2,2===Q&&(X?X(h):rt())},z="undefined"!=typeof window?window:void 0,B=z||{},Z=B.MutationObserver||B.WebKitMutationObserver,tt="undefined"==typeof self&&"undefined"!=typeof e&&"[object process]"==={}.toString.call(e),et="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel,nt=new Array(1e3),rt=void 0;rt=tt?u():Z?a():et?f():void 0===z?p():l();var ot=Math.random().toString(36).substring(16),it=void 0,st=1,ut=2,ct=new P,at=new P,ft=0;return R.prototype._enumerate=function(){for(var t=this.length,e=this._input,n=0;this._state===it&&n<t;n++)this._eachEntry(e[n],n)},R.prototype._eachEntry=function(t,e){var n=this._instanceConstructor,r=n.resolve;if(r===v){var o=w(t);if(o===d&&t._state!==it)this._settledAt(t._state,e,t._result);else if("function"!=typeof o)this._remaining--,this._result[e]=t;else if(n===Y){var i=new n(m);A(i,t,o),this._willSettleAt(i,e)}else this._willSettleAt(new n(function(e){return e(t)}),e)}else this._willSettleAt(r(t),e)},R.prototype._settledAt=function(t,e,n){var r=this.promise;r._state===it&&(this._remaining--,t===ut?j(r,n):this._result[e]=n),0===this._remaining&&S(r,this._result)},R.prototype._willSettleAt=function(t,e){var n=this;O(t,void 0,function(t){return n._settledAt(st,e,t)},function(t){return n._settledAt(ut,e,t)})},Y.all=J,Y.race=I,Y.resolve=v,Y.reject=U,Y._setScheduler=i,Y._setAsap=s,Y._asap=$,Y.prototype={constructor:Y,then:d,catch:function(t){return this.then(null,t)}},W(),Y.polyfill=W,Y.Promise=Y,Y})}).call(e,n(2),function(){return this}())},function(t,e){function n(){throw new Error("setTimeout has not been defined")}function r(){throw new Error("clearTimeout has not been defined")}function o(t){if(f===setTimeout)return setTimeout(t,0);if((f===n||!f)&&setTimeout)return f=setTimeout,setTimeout(t,0);try{return f(t,0)}catch(e){try{return f.call(null,t,0)}catch(e){return f.call(this,t,0)}}}function i(t){if(l===clearTimeout)return clearTimeout(t);if((l===r||!l)&&clearTimeout)return l=clearTimeout,clearTimeout(t);try{return l(t)}catch(e){try{return l.call(null,t)}catch(e){return l.call(this,t)}}}function s(){v&&p&&(v=!1,p.length?d=p.concat(d):m=-1,d.length&&u())}function u(){if(!v){var t=o(s);v=!0;for(var e=d.length;e;){for(p=d,d=[];++m<e;)p&&p[m].run();m=-1,e=d.length}p=null,v=!1,i(t)}}function c(t,e){this.fun=t,this.array=e}function a(){}var f,l,h=t.exports={};!function(){try{f="function"==typeof setTimeout?setTimeout:n}catch(t){f=n}try{l="function"==typeof clearTimeout?clearTimeout:r}catch(t){l=r}}();var p,d=[],v=!1,m=-1;h.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];d.push(new c(t,e)),1!==d.length||v||o(u)},c.prototype.run=function(){this.fun.apply(null,this.array)},h.title="browser",h.browser=!0,h.env={},h.argv=[],h.version="",h.versions={},h.on=a,h.addListener=a,h.once=a,h.off=a,h.removeListener=a,h.removeAllListeners=a,h.emit=a,h.prependListener=a,h.prependOnceListener=a,h.listeners=function(t){return[]},h.binding=function(t){throw new Error("process.binding is not supported")},h.cwd=function(){return"/"},h.chdir=function(t){throw new Error("process.chdir is not supported")},h.umask=function(){return 0}},function(t,e){}])});
//# sourceMappingURL=domo.js.map
{
"name": "ryuu.js",
"version": "2.5.9",
"version": "2.5.10",
"description": "Ryuu JavaScript Utility Library",

@@ -5,0 +5,0 @@ "main": "dist/domo.js",

@@ -66,2 +66,5 @@ require('es6-promise').polyfill(); // Promise polyfill for older browsers

window.addEventListener('message', function(event) {
if (!isVerifiedOrigin(event.origin))
return;
if (typeof event.data === 'string') {

@@ -109,2 +112,14 @@ try {

domo.__util = {
isVerifiedOrigin,
getQueryParams,
setFormatHeaders
}
function isVerifiedOrigin(origin) {
var whitelisted = origin.match('^https?://([^/]+[.])?(domo|domotech|domorig)\.(com|io)?(/.*)?$');
var blacklisted = origin.match('(.*)\.(domoapps)\.(.*)');
return !!whitelisted && !blacklisted;
}
function getQueryParams() {

@@ -111,0 +126,0 @@ var query = location.search.substr(1);

requirejs(['/dist/domo.js'], function(domo) {
assertDomoExists(domo);
assertOriginVerified(domo);
});
assertDomoExists(domo);
assertOriginVerified(domo);

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

function assert(result, value, message) {
if (value !== result) {
console.log(message);
return false;
}
return true;
}
function assertDomoExists(domo) {

@@ -8,1 +16,27 @@ if (typeof domo === 'function' && typeof domo.get === 'function') {

}
function assertOriginVerified(domo) {
var isVerifiedOrigin = domo.__util['isVerifiedOrigin'];
var arr = [
assert(isVerifiedOrigin('https://www.domo.com'), true, 'https://www.domo.com failed test'),
assert(isVerifiedOrigin('https://www.domorig.io'), true, 'https://www.domorig.io failed test'),
assert(isVerifiedOrigin('https://www.domotech.io'), true, 'https://www.domotech.io failed test'),
assert(isVerifiedOrigin('https://domo.demo.domo.com'), true, 'https://domo.demo.domo.com failed test'),
assert(isVerifiedOrigin('https://domoapps.prod3.domo.com'), false, 'https://domoapps.prod3.domo.com failed test'),
assert(isVerifiedOrigin('https://qa2staging.fastage1.domotech.io/auth/index'), true, 'https://qa2staging.fastage1.domotech.io/auth/index failed test'),
assert(isVerifiedOrigin('https://www.somethingk.com'), false, 'https://www.somethingk.com failed test'),
assert(isVerifiedOrigin('https://www.domo.com.bad.io'), false, 'https://www.domo.com.bad.io failed test'),
assert(isVerifiedOrigin('https://www.domo.com/stuff'), true, 'https://www.domo.com/stuff failed test'),
assert(isVerifiedOrigin('https://www.domoapps-test.domo.com/stuff'), false, 'https://www.domoapps-test.domo.com/stuff failed test'),
assert(isVerifiedOrigin('https://www.test-domoapps.domo.com/stuff'), false, 'https://www.test-domoapps.domo.com/stuff failed test')
]
if (arr.every(function (result) {
return result;
})) {
console.log('domo origin check passed');
} else {
console.log('domo origin check failed');
}
}

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc