Commit Graph

7493 Commits (9aaf78154818e93af5ade905202048dc8b6bdb0a)

Author SHA1 Message Date
Richard Hansen 9aaf781548 PadMessageHandler: Modernize `userLeave` hook context properties 2021-10-30 03:07:44 -04:00
Richard Hansen a6d060d67b PadMessageHandler: Replace `clientReady` hook with new `userJoin` hook 2021-10-30 03:07:44 -04:00
Richard Hansen c98910e1c5 PadMessageHandler: Populate session info as early as possible 2021-10-30 03:07:44 -04:00
Richard Hansen b7de24c85f PadMessageHandler: Fix readability of duplicate user check 2021-10-30 03:07:44 -04:00
Richard Hansen 00e7b04518 PadMessageHandler: Improve readability of changeset loading 2021-10-30 03:07:44 -04:00
Richard Hansen 50b9e0df1f PadMessageHandler: Use values from session info object
This is more consistent with the rest of the code, and it provides a
single source of truth.
2021-10-30 03:07:40 -04:00
Richard Hansen 10e930408c PadMessageHandler: Delete unnecessary CLIENT_READY checks
The checks are already performed by the security manager.
2021-10-30 03:06:57 -04:00
Richard Hansen 0992f19570 PadMessageHandler: Improve readability of historical author fetch 2021-10-30 03:06:57 -04:00
Richard Hansen d36a37d666 PadMessageHandler: Delete unnecessary `protocolVersion`
We can assume that the client code is always in sync with what the
server expects.
2021-10-30 03:06:57 -04:00
Richard Hansen ce730b0493 PadMessageHandler: Inline `createSessionInfoAuth()`
This function is only used once so it doesn't need to be separate.
2021-10-30 03:06:57 -04:00
Richard Hansen fa54dc1053 PadMessageHandler: Run the `clientReady` hook asynchronously 2021-10-30 03:06:57 -04:00
Richard Hansen 5d30e0b1b2 PadMessageHandler: Run the `userLeave` hook asynchronously 2021-10-30 03:06:57 -04:00
Richard Hansen f2a118b311 PadMessageHandler: Inline unnecessary variables
Also delete some unneccessary comments.
2021-10-30 03:06:15 -04:00
Richard Hansen 7522d76c40 PadMessageHandler: Invert condition to improve readability 2021-10-30 03:03:19 -04:00
Richard Hansen a3b4d985ac lint: Fix awkward string formatting 2021-10-30 03:03:19 -04:00
Richard Hansen f4f3aa6aae docs: Improve `userLeave` and `clientReady` hook documentation 2021-10-30 03:03:19 -04:00
Richard Hansen 80e84636d7 pad: Promisify `handshake()` 2021-10-29 19:38:28 -04:00
Richard Hansen cd4f5ff281 pad: Defer message handling until handshake completes 2021-10-29 19:37:28 -04:00
Richard Hansen be0298290d pad: Move post-handshake code to `_afterHandshake()` 2021-10-29 19:27:33 -04:00
Richard Hansen 9fb754ce3a pad: Initialize pad cookie before starting the handshake 2021-10-29 19:27:33 -04:00
Richard Hansen f6c5ce606e pad: Move UI setup from `handshake()` to `init()` 2021-10-29 19:27:33 -04:00
Richard Hansen bd44a87388 pad: Unexport unnecessarily exported `handshake()` function 2021-10-29 19:27:33 -04:00
Richard Hansen 5cbbcbcee6 pad: Simplify reload after `.etherpad` import
The old "switch to pad" logic looked buggy, and it complicates pad
initialization. Forcing a refresh after importing an `.etherpad` file
isn't much of a UX downgrade.
2021-10-29 19:27:33 -04:00
Richard Hansen e974622561 pad: Use `window.` to avoid ESLint error 2021-10-29 19:27:33 -04:00
webzwo0i d8ca3a693d timeslider scrollTo: fixes wrong line number calculation in case there
are no attribute changes and no length changes
2021-10-29 02:38:29 -04:00
webzwo0i 9bad1d03d3 importHtml: do not add an useless identity changeset 2021-10-29 02:29:45 -04:00
webzwo0i f7f5e3dad8 setText: prevent adding useless revision in case the pad text did not
change
2021-10-29 02:29:45 -04:00
webzwo0i 63de249236 tests: do not re-add identical text with setText 2021-10-29 02:29:45 -04:00
webzwo0i 668d62fa3f importHtml: avoid race when applying empty document and the import changeset at the same time 2021-10-29 02:29:45 -04:00
snyk-bot 8eb5640cb7 fix: upgrade express-rate-limit from 5.4.0 to 5.4.1
Snyk has created this PR to upgrade express-rate-limit from 5.4.0 to 5.4.1.

See this package in npm:
https://www.npmjs.com/package/express-rate-limit

See this project in Snyk:
https://app.snyk.io/org/johnmclear/project/d9a12bfb-7ccd-443f-9e22-f30d339cc8c5?utm_source=github&utm_medium=referral&page=upgrade-pr
2021-10-29 02:25:09 -04:00
snyk-bot dd8608fe6e fix: upgrade rate-limiter-flexible from 2.3.0 to 2.3.1
Snyk has created this PR to upgrade rate-limiter-flexible from 2.3.0 to 2.3.1.

See this package in npm:
https://www.npmjs.com/package/rate-limiter-flexible

See this project in Snyk:
https://app.snyk.io/org/johnmclear/project/d9a12bfb-7ccd-443f-9e22-f30d339cc8c5?utm_source=github&utm_medium=referral&page=upgrade-pr
2021-10-29 02:22:24 -04:00
snyk-bot cea7eb8ba6
fix: upgrade mime-types from 2.1.32 to 2.1.33
Snyk has created this PR to upgrade mime-types from 2.1.32 to 2.1.33.

See this package in npm:
https://www.npmjs.com/package/mime-types

See this project in Snyk:
https://app.snyk.io/org/johnmclear/project/d9a12bfb-7ccd-443f-9e22-f30d339cc8c5?utm_source=github&utm_medium=referral&page=upgrade-pr
2021-10-26 10:12:27 +00:00
snyk-bot 0d67d05b78 fix: upgrade express-rate-limit from 5.3.0 to 5.4.0
Snyk has created this PR to upgrade express-rate-limit from 5.3.0 to 5.4.0.

See this package in npm:
https://www.npmjs.com/package/express-rate-limit

See this project in Snyk:
https://app.snyk.io/org/johnmclear/project/d9a12bfb-7ccd-443f-9e22-f30d339cc8c5?utm_source=github&utm_medium=referral&page=upgrade-pr
2021-10-25 19:10:13 -04:00
translatewiki.net 2c15ae6ac9 Localisation updates from https://translatewiki.net. 2021-10-25 13:04:22 +02:00
Richard Hansen 4a8c72a38c Changeset: Minimize changeset docs, add links to code
This reduces the amount of duplicate documentation, and helps keep the
documentation and code in sync.
2021-10-24 21:29:42 -04:00
Richard Hansen de3dfb5ce2 AttributePool: Add JSDoc comments 2021-10-24 21:18:56 -04:00
Richard Hansen c98b521539 AttributePool: Use ES6 class syntax 2021-10-24 21:18:56 -04:00
webzwo0i bbc8b29ffd Changeset: Improve JSDoc comments
Co-authored-by: Richard Hansen <rhansen@rhansen.org>
2021-10-24 21:18:56 -04:00
snyk-bot 2c15e68e4a
fix: upgrade clean-css from 5.2.0 to 5.2.1
Snyk has created this PR to upgrade clean-css from 5.2.0 to 5.2.1.

See this package in npm:
https://www.npmjs.com/package/clean-css

See this project in Snyk:
https://app.snyk.io/org/johnmclear/project/d9a12bfb-7ccd-443f-9e22-f30d339cc8c5?utm_source=github&utm_medium=referral&page=upgrade-pr
2021-10-22 07:26:47 +00:00
snyk-bot 41e2ee4848
fix: upgrade rate-limiter-flexible from 2.2.4 to 2.3.0
Snyk has created this PR to upgrade rate-limiter-flexible from 2.2.4 to 2.3.0.

See this package in npm:
https://www.npmjs.com/package/rate-limiter-flexible

See this project in Snyk:
https://app.snyk.io/org/johnmclear/project/d9a12bfb-7ccd-443f-9e22-f30d339cc8c5?utm_source=github&utm_medium=referral&page=upgrade-pr
2021-10-20 08:24:39 +00:00
snyk-bot ccd7a8d5ff fix: upgrade threads from 1.6.5 to 1.7.0
Snyk has created this PR to upgrade threads from 1.6.5 to 1.7.0.

See this package in npm:
https://www.npmjs.com/package/threads

See this project in Snyk:
https://app.snyk.io/org/johnmclear/project/d9a12bfb-7ccd-443f-9e22-f30d339cc8c5?utm_source=github&utm_medium=referral&page=upgrade-pr
2021-10-17 02:32:13 -04:00
snyk-bot 1a008ed6fa
fix: upgrade clean-css from 5.1.5 to 5.2.0
Snyk has created this PR to upgrade clean-css from 5.1.5 to 5.2.0.

See this package in npm:
https://www.npmjs.com/package/clean-css

See this project in Snyk:
https://app.snyk.io/org/johnmclear/project/d9a12bfb-7ccd-443f-9e22-f30d339cc8c5?utm_source=github&utm_medium=referral&page=upgrade-pr
2021-10-17 06:17:34 +00:00
Richard Hansen 4f283b64cf tests: easysync: Inline some functions that are only used once 2021-10-17 00:49:34 +02:00
Richard Hansen e535129f3c tests: easysync: Use `expect.js` for checks 2021-10-17 00:49:34 +02:00
Richard Hansen ebb7dfabd7 tests: easysync: Use mocha `describe()` and `it()` 2021-10-17 00:49:34 +02:00
Richard Hansen 2c7d0604c3 tests: easysync: Remove unnecessary `Random` class 2021-10-17 00:49:34 +02:00
Richard Hansen 8dd61f847e tests: easysync: Fix some ESLint errors 2021-10-17 00:49:34 +02:00
Richard Hansen 59a6a9f6a0 tests: easysync: Delete commented-out and unused code 2021-10-17 00:49:34 +02:00
Richard Hansen 428736cdc3 tests: easysync: Run with the frontend tests 2021-10-17 00:49:34 +02:00
snyk-bot 3722d943c7
fix: upgrade terser from 5.8.0 to 5.9.0
Snyk has created this PR to upgrade terser from 5.8.0 to 5.9.0.

See this package in npm:
https://www.npmjs.com/package/terser

See this project in Snyk:
https://app.snyk.io/org/johnmclear/project/d9a12bfb-7ccd-443f-9e22-f30d339cc8c5?utm_source=github&utm_medium=referral&page=upgrade-pr
2021-10-13 07:15:16 +00:00