File tree Expand file tree Collapse file tree 2 files changed +8
-6
lines changed
Expand file tree Collapse file tree 2 files changed +8
-6
lines changed Original file line number Diff line number Diff line change 1+ # Master
2+
3+ ### Internal Changes
4+
5+ - 现在保存通过 ` AV.File.withURL ` 方法创建的文件等同于直接在 \_ File 中添加一行数据,不再自动生成 ` mime_type ` 。
6+
17# 4.7.0(2020-07-14)
28
39### Features
Original file line number Diff line number Diff line change @@ -183,6 +183,7 @@ module.exports = function(AV) {
183183 file . attributes . url = url ;
184184 //Mark the file is from external source.
185185 file . attributes . metaData . __source = 'external' ;
186+ file . attributes . metaData . size = 0 ;
186187 return file ;
187188 } ;
188189
@@ -595,18 +596,13 @@ module.exports = function(AV) {
595596 } ;
596597 this . _previousSave = AVRequest (
597598 'files' ,
598- this . attributes . name ,
599+ null ,
599600 null ,
600601 'post' ,
601602 data ,
602603 options
603604 ) . then ( response => {
604- this . attributes . name = response . name ;
605- this . attributes . url = response . url ;
606605 this . id = response . objectId ;
607- if ( response . size ) {
608- this . attributes . metaData . size = response . size ;
609- }
610606 return this ;
611607 } ) ;
612608 }
You can’t perform that action at this time.
0 commit comments