Skip to content

Commit

Permalink
Merge pull request #7 from clowdcontrol/static_server
Browse files Browse the repository at this point in the history
fix: omg sorry forgot this file
  • Loading branch information
akeshavan authored Jun 24, 2017
2 parents 2f9478b + c349ca2 commit bad4f9b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions imports/startup/fill_empty_db.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,11 @@ if (Meteor.isServer) {
source_json = Meteor.settings.public.startup_json //JSON.parse(Assets.getText("generator.json"));
//console.log(HTTP.get(source_json).content)
myobject = JSON.parse(HTTP.get(source_json).content)
//console.log("my object is", myobject.length)
if (Meteor.settings.load_if_empty){
console.log("my object is", myobject.length)
if (Meteor.settings.public.load_if_empty){
console.log("loading???")
myobject.forEach(function(val,idx,array){
console.log(val.subject_id)
Subjects.insert(val)
})
}
Expand Down

0 comments on commit bad4f9b

Please sign in to comment.