mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-29 07:09:48 +03:00
12 lines
309 B
JavaScript
12 lines
309 B
JavaScript
|
import Ember from 'ember';
|
||
|
import XFileInput from 'emberx-file-input/components/x-file-input';
|
||
|
|
||
|
const {testing} = Ember;
|
||
|
|
||
|
export default XFileInput.extend({
|
||
|
change(e) {
|
||
|
let files = testing ? (e.originalEvent || e).testingFiles : e.target.files;
|
||
|
this.sendAction('action', files);
|
||
|
}
|
||
|
});
|