Richard Hansen
8f236b8687
Minify: Avoid crash due to unhandled Promise rejection if stat fails
2021-05-03 01:26:49 -04:00
Richard Hansen
e8df643d75
Minify: Treat ENOTDIR
like ENOENT
when statting a file
...
This avoids an exception when require-kernel requests a path like
`existing-file.js/index.js`.
2021-05-03 01:26:48 -04:00
Richard Hansen
aaacbd3a7a
Minify: Refactor requestURI()
for readability
2021-05-03 01:26:48 -04:00
Richard Hansen
ea8846154f
favicon: Redo favicon customization
2021-04-20 13:33:55 -04:00
Richard Hansen
92e0bff80c
favicon: Refactor handler and add tests
2021-04-20 13:33:55 -04:00
Richard Hansen
d0d4b95980
favicon: Only serve from /favicon.ico
2021-04-20 13:33:54 -04:00
webzwo0i
3a5af19492
AuthorManager: await for more db methods
2021-04-20 11:27:44 -04:00
webzwo0i
35797e57fc
AuthorManager: await db.set in createAuthor
2021-04-20 11:27:44 -04:00
Chocobozzz
a001a13411
fix(perf): Disable wtfnode dump by default
...
Consumes a lot of CPU so it's better to enable it on purpose
2021-04-13 16:01:41 +02:00
Richard Hansen
951d369e3f
padaccess: Delete useless try/catch
2021-04-12 22:51:06 -04:00
Richard Hansen
329d037431
Simplify read-only pad ID checks
2021-04-12 22:51:06 -04:00
pcworld
3c71e8983b
Fix read only pad access with authentication
...
Before this commit, webaccess.checkAccess saved the authorization in
user.padAuthorizations[padId] with padId being the read-only pad ID,
however later stages, e.g. in PadMessageHandler, use the real pad ID for
access checks. This led to authorization being denied.
This commit fixes it by only storing and comparing the real pad IDs and
not read-only pad IDs.
This fixes test case "authn user readonly pad -> 200, ok" in
src/tests/backend/specs/socketio.js.
2021-04-12 22:51:06 -04:00
Richard Hansen
1ad134a538
PadMessageHandler: Improve logging of pre-CLIENT_READY drops
...
This should make it easier to see what is emitting the the messages so
it can be fixed.
2021-04-09 18:43:02 +02:00
Richard Hansen
91e99c84ca
import: Reduce log spam from unsupported elements
2021-04-09 18:43:02 +02:00
Richard Hansen
09c349e2a1
import: Use a Set for supported elements
2021-04-09 18:43:02 +02:00
webzwo0i
e483b91916
Don't make browsers fail on sync-xhr until require-kernel is dropped
2021-04-05 04:34:29 -04:00
Richard Hansen
eb3cff5b3a
LibreOffice: Remove unnecessary callbackification
...
`async.queue` will do the right thing if passed an `async` function.
2021-03-20 20:29:55 +00:00
Richard Hansen
0233399fdf
Abiword: Avoid calling stdoutCallback
multiple times
2021-03-20 20:29:55 +00:00
Richard Hansen
3ad1d0a74f
cssmanager: Refactor CSS manager creation to avoid race condition
...
Safari takes a while to initialize `document.styleSheets`, which
results in a race condition when loading the pad. Avoid the race
condition by accessing the CSSStyleSheet objects directly from the
HTMLStyleElement DOM objects.
2021-03-20 01:07:16 +00:00
Richard Hansen
b4e1e935e2
LibreOffice: Log conversion errors
2021-03-18 09:02:28 +00:00
Richard Hansen
b2c0837cf5
import/export: Promisify Abiword and LibreOffice conversion
2021-03-18 09:02:28 +00:00
Richard Hansen
b321267e66
LibreOffice: Use the async-provided callback to signal errors
...
This avoids having two callbacks, which improves readability.
2021-03-18 09:02:28 +00:00
Richard Hansen
b914a46a87
LibreOffice: Use async.series
to properly handle conversion errors
2021-03-18 09:02:28 +00:00
Richard Hansen
a6d5611c80
LibreOffice: Use consistent intermediate filename
2021-03-18 09:02:28 +00:00
Richard Hansen
ad0be9d1d2
LibreOffice: Add missing fileExtension
property on intermediate step
2021-03-18 09:02:28 +00:00
Richard Hansen
5eab3a123d
Abiword: Use the async-provided callback to signal errors
...
This avoids having two callbacks, which improves readability.
2021-03-18 09:02:28 +00:00
Richard Hansen
8d32463915
Abiword: Fix logging of conversion failure
2021-03-18 09:02:28 +00:00
Richard Hansen
f015f59cfc
Abiword: Reduce log spam
2021-03-18 09:02:28 +00:00
Richard Hansen
259ee4a987
Abiword: Don't call the callback if null
2021-03-18 09:02:28 +00:00
Richard Hansen
83f39289aa
import/export: On export error return 500 instead of crashing
2021-03-18 09:02:28 +00:00
Richard Hansen
3a11e97758
import/export: Spelling fix: "convertor" -> "converter"
2021-03-18 09:02:28 +00:00
Richard Hansen
50fdadab7d
ExportHandler: Pass the error unmodified
2021-03-18 09:02:28 +00:00
Richard Hansen
216aecd433
import/export: Use Error objects for errors, not strings
2021-03-18 09:02:28 +00:00
Richard Hansen
59c167e31b
ExportHandler: Replace unnecessary exception with return
2021-03-18 09:02:28 +00:00
Richard Hansen
785b7d2b44
Abiword: Reset stdout buffer when starting abiword
2021-03-18 09:02:28 +00:00
Richard Hansen
b6c2586920
import/export: Delete unnecessary comments
2021-03-18 09:02:28 +00:00
Richard Hansen
9b82d1d37d
server: Log stats (metrics) on fatal error
...
This might help users troubleshoot rare crashes.
2021-03-11 07:38:44 +00:00
Richard Hansen
fcf43a7089
stats: Expose ueberDB metrics
2021-03-08 22:32:39 +00:00
webzwo0i
4ca989a255
sessions: add more endpoints that do not need a session ( #4921 )
...
* add more endpoints that do not need a session
* Update src/node/hooks/express/webaccess.js
Co-authored-by: Richard Hansen <rhansen@rhansen.org>
* Update src/node/hooks/express/webaccess.js
Co-authored-by: Richard Hansen <rhansen@rhansen.org>
Co-authored-by: John McLear <john@mclear.co.uk>
Co-authored-by: Richard Hansen <rhansen@rhansen.org>
2021-03-05 07:48:33 +00:00
Richard Hansen
0aad3b74da
pluginfw: Improve rendering of hook list
...
There are two main benefits:
* HTML is no longer printed in the startup debug logs.
* `require()` is no longer called on client-side files. This
eliminates "Failed to load <file> for <plugin>: ReferenceError:
window is not defined" errors when users visit
`/admin/plugins/info`.
2021-03-03 11:19:37 +00:00
John McLear
f95b09e0b6
Import: Import don't show warnings for supported elements
2021-03-02 17:14:47 +00:00
Richard Hansen
797ffa5600
Minify: Avoid path.relative()
...
Constructing a relative pathname on Windows is problematic because the
two absolute pathnames might be on different drives (or UNC paths).
Use `path.resolve()` instead of `path.join()` where appropriate to
avoid the need to construct a relative path.
2021-03-02 06:20:10 +00:00
Richard Hansen
b0862cd030
ace: Delete all $$INCLUDE_CSS
logic
...
The intention of the deleted code was to reduce the number of fetches,
but it only saved a single fetch due to implementation flaws. The
right way to reduce the number of fetches is to use a bundling
technology such as webpack, and this change makes it easier to do so.
2021-03-01 14:32:33 +00:00
Richard Hansen
99b3918f2c
Minify: Compatibility for all vendors/*.js
files
2021-02-28 11:12:30 +00:00
webzwo0i
377883db98
fix pads with spaces ( #4884 )
2021-02-27 22:34:43 -05:00
webzwo0i
01dd9f5440
speed up page load
2021-02-27 16:28:12 +00:00
Richard Hansen
f86df5322e
CachingMiddleware: Asyncify
2021-02-27 14:03:09 +01:00
Richard Hansen
0284d49522
CachingMiddleware: Switch to ES6 class syntax
2021-02-27 14:03:09 +01:00
Richard Hansen
80af66543a
lint: Move up respond()
in caching_middleware.js
2021-02-27 14:03:09 +01:00
Richard Hansen
7ab3ee2121
lint: src/node/utils/caching_middleware.js
2021-02-27 14:03:09 +01:00