소스 검색

plugin-removed --> plugin-remove

Artur Paikin 6 년 전
부모
커밋
bd4b89d76e
2개의 변경된 파일3개의 추가작업 그리고 3개의 파일을 삭제
  1. 1 1
      src/core/Core.js
  2. 2 2
      src/plugins/Dashboard/index.js

+ 1 - 1
src/core/Core.js

@@ -886,7 +886,7 @@ class Uppy {
    * @param {object} instance The plugin instance to remove.
    */
   removePlugin (instance) {
-    this.emit('plugin-removed', instance)
+    this.emit('plugin-remove', instance)
 
     if (instance.uninstall) {
       instance.uninstall()

+ 2 - 2
src/plugins/Dashboard/index.js

@@ -374,7 +374,7 @@ module.exports = class Dashboard extends Plugin {
     this.updateDashboardElWidth()
     window.addEventListener('resize', this.updateDashboardElWidth)
 
-    this.uppy.on('plugin-removed', this.removeTarget)
+    this.uppy.on('plugin-remove', this.removeTarget)
   }
 
   removeEvents () {
@@ -386,7 +386,7 @@ module.exports = class Dashboard extends Plugin {
     this.removeDragDropListener()
     window.removeEventListener('resize', this.updateDashboardElWidth)
 
-    this.uppy.off('plugin-removed', this.removeTarget)
+    this.uppy.off('plugin-remove', this.removeTarget)
   }
 
   updateDashboardElWidth () {