diff options
Diffstat (limited to 'js/directive/NewsReadFile.js')
-rw-r--r-- | js/directive/NewsReadFile.js | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/js/directive/NewsReadFile.js b/js/directive/NewsReadFile.js index 89ed0adfc..82bdf477e 100644 --- a/js/directive/NewsReadFile.js +++ b/js/directive/NewsReadFile.js @@ -7,17 +7,17 @@ * @author Bernhard Posselt <dev@bernhard-posselt.com> * @copyright Bernhard Posselt 2014 */ -app.directive('newsReadFile', () => { +app.directive('newsReadFile', function () { 'use strict'; - return (scope, elem, attr) => { + return function (scope, elem, attr) { - elem.change(() => { + elem.change(function () { - let file = elem[0].files[0]; - let reader = new FileReader(); + var file = elem[0].files[0]; + var reader = new FileReader(); - reader.onload = (event) => { + reader.onload = function (event) { elem[0].value = 0; // FIXME: is there a more flexible solution where we dont have // to bind the file to scope? |