Skip to content

Commit badf7c0

Browse files
authored
Merge pull request DuendeArchive#410 from amorokh/dev
Make oidc-client ReactNative-friendly
2 parents 7b85ae0 + f609327 commit badf7c0

File tree

4 files changed

+8
-5
lines changed

4 files changed

+8
-5
lines changed

src/Event.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ export default class Event {
2323

2424
raise(...params) {
2525
Log.debug("Raising event: " + this._name);
26-
for (var cb of this._callbacks) {
27-
cb(...params);
26+
for (let i = 0; i < this._callbacks.length; i++) {
27+
this._callbacks[i](...params);
2828
}
2929
}
3030
}

src/ResponseValidator.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,8 @@ export default class ResponseValidator {
166166
values = [values];
167167
}
168168

169-
for (let value of values) {
169+
for (let i = 0; i < values.length; i++) {
170+
let value = values[i];
170171
if (!result[name]) {
171172
result[name] = value;
172173
}

src/State.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@ export default class State {
5050
Log.debug("got keys", keys);
5151

5252
var promises = [];
53-
for (let key of keys) {
53+
for (let i = 0; i < keys.length; i++) {
54+
let key = keys[i];
5455
var p = storage.get(key).then(item => {
5556
let remove = false;
5657

webpack.base.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@ var createWebpackConfig = function(options) {
55
output: options.output,
66
plugins: options.plugins,
77
node: {
8-
fs: 'empty' // Because of jsrsasign usage of fs
8+
fs: 'empty', // Because of jsrsasign usage of fs
9+
buffer: 'empty',
910
},
1011
module: {
1112
loaders: [

0 commit comments

Comments
 (0)