Ajout du choix des utilisateurs sur un événement. Ajout de fichiers dans un événement. (dropzone cassée)

This commit is contained in:
2025-05-26 22:10:40 +02:00
parent 82d77e2b8d
commit 49dffff1bf
1100 changed files with 157519 additions and 113 deletions

35
em2rp/node_modules/stubs/index.js generated vendored Normal file
View File

@ -0,0 +1,35 @@
'use strict'
module.exports = function stubs(obj, method, cfg, stub) {
if (!obj || !method || !obj[method])
throw new Error('You must provide an object and a key for an existing method')
if (!stub) {
stub = cfg
cfg = {}
}
stub = stub || function() {}
cfg.callthrough = cfg.callthrough || false
cfg.calls = cfg.calls || 0
var norevert = cfg.calls === 0
var cached = obj[method].bind(obj)
obj[method] = function() {
var args = [].slice.call(arguments)
var returnVal
if (cfg.callthrough)
returnVal = cached.apply(obj, args)
returnVal = stub.apply(obj, args) || returnVal
if (!norevert && --cfg.calls === 0)
obj[method] = cached
return returnVal
}
}