Skip to content

Commit

Permalink
Fix ReactiveDic initialization
Browse files Browse the repository at this point in the history
  • Loading branch information
Théo mathieu committed Jun 15, 2016
1 parent 4c5f948 commit 9e6cce8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/Meteor.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import composeWithTracker from './components/composeWithTracker';
import FSCollection from './CollectionFS/FSCollection';
import FSCollectionImagesPreloader from './CollectionFS/FSCollectionImagesPreloader';

import ReactiveDict from './ReactDict';
import ReactiveDict from './ReactiveDict';

import User from './user/User';
import Accounts from './user/Accounts';
Expand Down
7 changes: 4 additions & 3 deletions src/ReactDict.js → src/ReactiveDict.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,11 @@ const parse = function (serialized) {

export default class ReactiveDict {
constructor(dictName) {
this.keys = {};
if (typeof dictName === 'object') {
this.keys = dictName;
} else {
this.keys = {};
for(var i in dictName) {
this.keys[i] = stringify(dictName[i])
}
}
}
set(keyOrObject, value) {
Expand Down

0 comments on commit 9e6cce8

Please sign in to comment.