From 8fc1ad906214b842d8a3e8ee4fae8dbf9b3e8cd8 Mon Sep 17 00:00:00 2001 From: Jan Kuri Date: Sun, 25 Dec 2016 06:44:01 +0100 Subject: [PATCH] fix(ngOnChanges): add parameter --- package.json | 2 +- src/directives/ng-file-drop.ts | 5 +++-- src/directives/ng-file-select.ts | 5 +++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index d9c9caee..0ecb881a 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "ngx-uploader", "description": "Angular File Uploader", - "version": "2.0.0", + "version": "2.0.1", "license": "MIT", "main": "index.js", "typings": "index.d.ts", diff --git a/src/directives/ng-file-drop.ts b/src/directives/ng-file-drop.ts index 4d34a052..df2d0aaf 100644 --- a/src/directives/ng-file-drop.ts +++ b/src/directives/ng-file-drop.ts @@ -7,7 +7,8 @@ import { HostListener, Inject, OnChanges, - OnInit + OnInit, + SimpleChange } from '@angular/core'; import { NgUploaderService } from '../services/ngx-uploader'; import { INgUploaderOptions, NgUploaderOptions, UploadedFile, UploadRejected } from '../classes'; @@ -59,7 +60,7 @@ export class NgFileDropDirective implements OnChanges, OnInit { this.initEvents(); } - ngOnChanges() { + ngOnChanges(changes: {[propName: string]: SimpleChange}) { if (!this.options) { return; } diff --git a/src/directives/ng-file-select.ts b/src/directives/ng-file-select.ts index 3841d094..edb3faa2 100644 --- a/src/directives/ng-file-select.ts +++ b/src/directives/ng-file-select.ts @@ -6,7 +6,8 @@ import { Output, HostListener, Inject, - OnChanges + OnChanges, + SimpleChange } from '@angular/core'; import { NgUploaderService } from '../services/ngx-uploader'; import { INgUploaderOptions, NgUploaderOptions, UploadedFile, UploadRejected } from '../classes'; @@ -28,7 +29,7 @@ export class NgFileSelectDirective implements OnChanges { @Inject(ElementRef) public el: ElementRef, @Inject(NgUploaderService) public uploader: NgUploaderService) { } - ngOnChanges() { + ngOnChanges(changes: {[propName: string]: SimpleChange}) { if (!this.options) { return; }