gd-app-install 1.0.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of gd-app-install might be problematic. Click here for more details.

package/package.json ADDED
@@ -0,0 +1,11 @@
1
+ {
2
+ "name": "gd-app-install",
3
+ "version": "1.0.0",
4
+ "description": "Kirbyn17@HackerOne",
5
+ "main": "lib/index.js",
6
+ "scripts": {
7
+ "test": "echo \"Error: no test specified\" && exit 1"
8
+ },
9
+ "author": "",
10
+ "license": "ISC"
11
+ }
@@ -0,0 +1,24 @@
1
+ export function(func, delay) {
2
+ var timeout;
3
+
4
+ return function() {
5
+ var context = this,
6
+ args = arguments;
7
+
8
+ if (timeout) {
9
+ // We're in the delay period. Clear old timeout (this is the actual debounce) and set a new one.
10
+ clearTimeout(timeout);
11
+ timeout = setTimeout(function() {
12
+ timeout = null;
13
+ func.apply(context, args);
14
+ }, delay);
15
+ }
16
+ else {
17
+ // No delay! Set a no-op timeout to start the delay clock.
18
+ func.apply(context, args);
19
+ timeout = setTimeout(function() {
20
+ timeout = null;
21
+ }, delay);
22
+ }
23
+ };
24
+ }
package/src/extend.ts ADDED
@@ -0,0 +1,25 @@
1
+ export function extend(out) {
2
+ out = out || {};
3
+
4
+ for (var i = 1; i < arguments.length; i++) {
5
+ var obj = arguments[i];
6
+
7
+ if (!obj) {
8
+ continue;
9
+ }
10
+
11
+ for (var key in obj) {
12
+ if (obj.hasOwnProperty(key)) {
13
+ if (typeof obj[key] === 'object') {
14
+ var cpy = out[key];
15
+ out[key] = extend(cpy, obj[key]);
16
+ }
17
+ else {
18
+ out[key] = obj[key];
19
+ }
20
+ }
21
+ }
22
+ }
23
+
24
+ return out;
25
+ }
package/src/index.ts ADDED
@@ -0,0 +1,3 @@
1
+ export function hello(name: string) {
2
+ return "Hello, " + name;
3
+ }