File tree Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -22,9 +22,14 @@ Template.afFileUpload.onCreated(function () {
2222 } ;
2323 }
2424
25- this . collection = Mongo . Collection . get
26- ? Mongo . Collection . get ( this . data . atts . collection ) . filesCollection
27- : ( global [ this . data . atts . collection ] || Meteor . connection . _mongo_livedata_collections [ this . data . atts . collection ] . filesCollection ) ;
25+ const mongoCollection = Mongo . Collection . get
26+ ? Mongo . Collection . get ( this . data . atts . collection )
27+ : Meteor . connection . _mongo_livedata_collections [ this . data . atts . collection ]
28+
29+ this . collection = mongoCollection
30+ ? mongoCollection . filesCollection
31+ : global [ this . data . atts . collection ]
32+
2833 this . uploadTemplate = this . data . atts . uploadTemplate || null ;
2934 this . previewTemplate = this . data . atts . previewTemplate || null ;
3035 this . insertConfig = Object . assign ( { } , this . data . atts . insertConfig || { } ) ;
Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ Package.describe({
22 name : 'ostrio:autoform-files' ,
33 summary : 'File upload for AutoForm using ostrio:files' ,
44 description : 'File upload for AutoForm using ostrio:files' ,
5- version : '2.1.1 ' ,
5+ version : '2.1.2 ' ,
66 git : 'https://github.com/VeliovGroup/meteor-autoform-file.git'
77} ) ;
88
You can’t perform that action at this time.
0 commit comments