invalidPluginWithoutId.js 420 B

12345678910111213141516171819
  1. const Plugin = require('../../packages/@uppy/core/lib/Plugin')
  2. module.exports = class InvalidPluginWithoutName extends Plugin {
  3. constructor (uppy, opts) {
  4. super(uppy, opts)
  5. this.type = 'acquirer'
  6. this.name = this.constructor.name
  7. }
  8. run (results) {
  9. this.uppy.log({
  10. class: this.constructor.name,
  11. method: 'run',
  12. results: results
  13. })
  14. return Promise.resolve('success')
  15. }
  16. }