Ignore:
Timestamp:
01/21/25 03:08:24 (3 days ago)
Author:
stefan toskovski <stefantoska84@…>
Branches:
main
Parents:
0c6b92a
Message:

F4 Finalna Verzija

File:
1 edited

Legend:

Unmodified
Added
Removed
  • imaps-frontend/node_modules/chokidar/index.js

    r0c6b92a r79a0317  
    33exports.FSWatcher = exports.WatchHelper = void 0;
    44exports.watch = watch;
     5/*! chokidar - MIT License (c) 2012 Paul Miller (paulmillr.com) */
    56const fs_1 = require("fs");
    67const promises_1 = require("fs/promises");
     
    433434    }
    434435    emitWithAll(event, args) {
    435         this.emit(...args);
     436        this.emit(event, ...args);
    436437        if (event !== handler_js_1.EVENTS.ERROR)
    437             this.emit(handler_js_1.EVENTS.ALL, ...args);
     438            this.emit(handler_js_1.EVENTS.ALL, event, ...args);
    438439    }
    439440    // Common helpers
     
    455456        if (opts.cwd)
    456457            path = sysPath.relative(opts.cwd, path);
    457         const args = [event, path];
     458        const args = [path];
    458459        if (stats != null)
    459460            args.push(stats);
     
    466467        if (opts.atomic) {
    467468            if (event === handler_js_1.EVENTS.UNLINK) {
    468                 this._pendingUnlinks.set(path, args);
     469                this._pendingUnlinks.set(path, [event, ...args]);
    469470                setTimeout(() => {
    470471                    this._pendingUnlinks.forEach((entry, path) => {
     
    477478            }
    478479            if (event === handler_js_1.EVENTS.ADD && this._pendingUnlinks.has(path)) {
    479                 event = args[0] = handler_js_1.EVENTS.CHANGE;
     480                event = handler_js_1.EVENTS.CHANGE;
    480481                this._pendingUnlinks.delete(path);
    481482            }
     
    484485            const awfEmit = (err, stats) => {
    485486                if (err) {
    486                     event = args[0] = handler_js_1.EVENTS.ERROR;
    487                     args[1] = err;
     487                    event = handler_js_1.EVENTS.ERROR;
     488                    args[0] = err;
    488489                    this.emitWithAll(event, args);
    489490                }
    490491                else if (stats) {
    491492                    // if stats doesn't exist the file must have been deleted
    492                     if (args.length > 2) {
    493                         args[2] = stats;
     493                    if (args.length > 1) {
     494                        args[1] = stats;
    494495                    }
    495496                    else {
     
    802803}
    803804exports.default = { watch, FSWatcher };
    804 //# sourceMappingURL=index.js.map
Note: See TracChangeset for help on using the changeset viewer.