From 3395a7baf56c63da9620003e75e5b303ec1fcbe7 Mon Sep 17 00:00:00 2001 From: Nathaniel Dsouza Date: Tue, 11 Aug 2020 18:21:50 -0400 Subject: [PATCH 1/5] Remove unused assignment to options --- src/Collection.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/Collection.js b/src/Collection.js index f624e6f..64d1909 100644 --- a/src/Collection.js +++ b/src/Collection.js @@ -154,7 +154,6 @@ export class Collection { update(id, modifier, options = {}, callback = () => {}) { if (typeof options == 'function') { callback = options; - options = {}; } if (!this._collection.get(id)) From 44eb1e31602079f551a4188a693ee705c456c286 Mon Sep 17 00:00:00 2001 From: Nathaniel Dsouza Date: Tue, 11 Aug 2020 18:22:43 -0400 Subject: [PATCH 2/5] Mark SHA256 insufficient as wontfix --- lib/utils.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/utils.js b/lib/utils.js index b31a8a0..b21c97e 100644 --- a/lib/utils.js +++ b/lib/utils.js @@ -8,7 +8,7 @@ export function uniqueId() { export function hashPassword(password) { return { - digest: SHA256(password).toString(), + digest: SHA256(password).toString(), // lgtm [js/insufficient-password-hash] algorithm: 'sha-256', }; } From 86939726add5fe124269282a8bec108a8f1dfada Mon Sep 17 00:00:00 2001 From: Nathaniel Dsouza Date: Tue, 11 Aug 2020 18:24:52 -0400 Subject: [PATCH 3/5] Remove unused variable self --- src/Collection.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/Collection.js b/src/Collection.js index 64d1909..f390644 100644 --- a/src/Collection.js +++ b/src/Collection.js @@ -201,7 +201,6 @@ export class Collection { } helpers(helpers) { - var self = this; let _transform; if (this._transform && !this._helpers) _transform = this._transform; From e9741d103a59bcdcfad9dd2bf9355e4f9d306c17 Mon Sep 17 00:00:00 2001 From: Nathaniel Dsouza Date: Tue, 11 Aug 2020 18:25:38 -0400 Subject: [PATCH 4/5] Remove unused variable serializedValue --- src/ReactiveDict.js | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/ReactiveDict.js b/src/ReactiveDict.js index e6f877e..6b0bc61 100644 --- a/src/ReactiveDict.js +++ b/src/ReactiveDict.js @@ -74,8 +74,6 @@ export default class ReactiveDict { ) throw new Error('ReactiveDict.equals: value must be scalar'); - const serializedValue = stringify(value); - let oldValue = undefined; if (Object.keys(this.keys).indexOf(key) != -1) { oldValue = parse(this.keys[key]); From b9be7c817b7aa3a9ea1315a3f42dd4dde34ed4e2 Mon Sep 17 00:00:00 2001 From: Nathaniel Dsouza Date: Tue, 11 Aug 2020 18:26:11 -0400 Subject: [PATCH 5/5] Remove unused state properties loading --- examples/Login.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/Login.jsx b/examples/Login.jsx index 44734b8..75e8ba2 100644 --- a/examples/Login.jsx +++ b/examples/Login.jsx @@ -4,7 +4,7 @@ import { withTracker, Meteor } from 'meteor-react-native'; class Login extends React.Component { - state = {email:"", password:"", loading:false}; + state = {email:"", password:""}; onLogin = () => { let { email, password } = this.state;