Commit graph

87 commits

Author SHA1 Message Date
David Mehren
d26dcd04a1
Adapt code for eslint-config-standard 17
Signed-off-by: David Mehren <git@herrmehren.de>
2022-05-01 21:19:44 +02:00
Philip Molares
136d895d15 Linter: Fix all lint errors
Signed-off-by: Philip Molares <philip.molares@udo.edu>
2021-02-15 12:15:14 +01:00
Amolith
71e900e9e8
remove unused variable to pass ci testing - #58
Signed-off-by: Amolith <amolith@nixnet.xyz>
2019-10-03 09:24:46 -04:00
Amolith
e6eab33e2d
remove legacy code to solve #58
Signed-off-by: Amolith <amolith@nixnet.xyz>
2019-10-03 08:39:51 -04:00
Sheogorath
b5fc6db75d
Rework debug logging
We have various places with overly simple if statements that could be
handled by our logging library. Also a lot of those logs are not marked
as debug logs but as info logs, which can cause confusion during
debugging.

This patch removed unneeded if clauses around debug logging statements,
reworks debug log messages towards ECMA templates and add some new
logging statements which might be helpful in order to debug things like
image uploads.

Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
2019-06-08 21:27:29 +02:00
Claudius Coenen
858a59529e switching to eslint for code checking
most rules degraded to WARN, so we don't go insane. This will
change over time. The aim is to conform to a common style

Signed-off-by: Claudius Coenen <opensource@amenthes.de>
2018-11-14 23:15:36 +01:00
Sheogorath
bcc914a773
Add full version string
Currently we only provide the version from `package.json`. This means
that during updates of instances, e.g. the demo instance, which runs
latest master instead of a stable release, changes are not reflected to
the webclient.

This patch adds a fullversion string that contains the current commit
and this way makes that clients are notified about changes.

Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
2018-11-11 12:44:19 +01:00
Sheogorath
e31d204d74
Fix requests for deleted users
When users are requested from the authorship which no longer exist, they
shouldn't cause a 500.

Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
2018-05-25 16:15:18 +02:00
Sheogorath
2492cf2cdf
Fix typos for allowAnonymousEdits
Looks like we lost some variables during the refactoring of the configs
to camel case.

This should fix it.

Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
2018-04-10 14:40:27 +02:00
Sheogorath
2411dffa2c
Change config to camel case with backwards compatibility
This refactors the configs a bit to now use camel case everywhere.
This change should help to clean up the config interface and make it
better understandable.

Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
2018-03-25 19:08:14 +02:00
Max Wu
baa0418fb5 Remove and replace all note id compression in LZString with base64url
Signed-off-by: Max Wu <jackymaxj@gmail.com>
2018-02-26 16:43:29 +08:00
Stefan Bühler
c4f8fb78ee don't require referer to find note id in socket.io connections (fixes #623)
Signed-off-by: Stefan Bühler <buehler@cert.uni-stuttgart.de>
2018-02-05 14:26:42 +01:00
Dario Ernst
6ae4b8bf13 Add option to enable freely permission in closed instance
Before, closed disallowed guest edits completely, by removing
the `freely` permission. This makes it possible to explicitely bring
back guest-editing, but not guest-note-creation, to closed instances.

Signed-off-by: Dario Ernst <dario@kanojo.de>
2018-01-20 15:14:56 +01:00
Max Wu
68879d20ed
Fix minor typos
of wrong parameters passing order and wrong user object indexing in for each function
2018-01-16 15:51:24 +08:00
BoHong Li
ecb0533605 refactor(config.js): Extract config file
* Separate different config source to each files
* Freeze config object
2017-05-08 19:29:07 +08:00
BoHong Li
aca01f064d refactor: Remove require extension filename 2017-05-08 19:29:06 +08:00
BoHong Li
5870d988b5 Use strict mode in all backend files
add ‘use strict’ in all backend file
2017-03-14 13:02:43 +08:00
BoHong Li
4889e9732d Use JavaScript Standard Style
Introduce JavaScript Standard Style as project style rule,
and fixed all fail on backend code.
2017-03-08 18:45:51 +08:00
Wu Cheng-Han
ef0ac7768d Update realtime to use timer to avoid memory leaks on busy tick 2017-02-03 21:47:38 +08:00
Wu Cheng-Han
92ad67b813 Update to remove history cache to lower application coupling 2017-02-03 21:39:08 +08:00
Wu Cheng-Han
1473437295 Refactor checkViewPermission to fix limited & protected permission check bug and fix code style 2017-01-16 23:47:53 +08:00
Wu Cheng-Han
3ee65cd38e Fix for limited and protected permissions should forbid guest in realtime events 2017-01-12 23:45:51 +08:00
Wu Cheng-Han
7e191acbde Fix author creation in operationCallback might cause unique constraint validation error 2017-01-12 17:18:24 +08:00
蒼時弦也
be7696170f Fix syntax when use case 2017-01-10 10:19:18 +08:00
蒼時弦也
89b8ddeaba Add limited and protected permission 2017-01-10 10:02:37 +08:00
Wu Cheng-Han
f6d8e3ab00 Remove LZString compression for data storage 2017-01-02 10:59:53 +08:00
Wu Cheng-Han
c904083d1f Remove manual LZString compression for partial socket io event data 2017-01-02 10:52:47 +08:00
Florian Rhiem
fdea226159 Fixed typo: anonmyous 2016-12-21 14:36:54 +01:00
Wu Cheng-Han
d140a140de Fix possible user is undefined in realtime events 2016-12-20 20:33:46 +08:00
Wu Cheng-Han
62eccd48e5 Try to fix when server have heavy loading cache might not update to db properly 2016-12-18 22:52:30 +08:00
Wu Cheng-Han
5c7eb48319 Add support of allow anonymous config option with correspond modifications 2016-12-15 14:11:23 +08:00
Wu Cheng-Han
a73d9ce39e Update to support optional email register and signin 2016-12-02 01:58:14 +08:00
Wu Cheng-Han
c58162a2e7 Revert "Add workers for notes to leverage CPU intensive work loading"
This reverts commit 4ccfdfa538.
2016-11-16 13:58:59 +08:00
Wu Cheng-Han
4ccfdfa538 Add workers for notes to leverage CPU intensive work loading 2016-11-07 21:30:40 +08:00
Wu Cheng-Han
1418b7a801 Fix socket disconnect might interrupt loop issue 2016-10-14 17:36:04 +08:00
Wu Cheng-Han
c98d263928 Fix to handle undefined document on update history 2016-10-12 17:50:36 +08:00
Wu Cheng-Han
b734eb9c85 Try to fix memory leaks by clear OT server before disconnect note 2016-10-10 21:05:49 +08:00
Wu Cheng-Han
12d5ed43a7 Update to support delete note 2016-10-10 21:04:24 +08:00
Wu Cheng-Han
d6d2cf978a Update to send note title on emit check and refresh event 2016-10-10 20:56:22 +08:00
Wu Cheng-Han
36a1900ce3 Update to make note history count in server-side when user logged 2016-10-10 20:55:33 +08:00
Wu Cheng-Han
b54b3cbe69 Add more comments in the code and remove unused code file 2016-10-10 20:48:56 +08:00
Wu Cheng-Han
1cae0c5b7f Update to prevent duplicate socket push in queue in order to lower down server loading 2016-10-10 20:25:48 +08:00
Wu Cheng-Han
d23ced1fba Update to move authorship calculation code to note model and support update authorship after making revision of docs 2016-10-10 20:23:33 +08:00
Wu Cheng-Han
79fd2d1364 Update to add revision saving policy 2016-09-18 16:50:20 +08:00
Wu Cheng-Han
e94810ff94 Update to change the last change user saving strategy 2016-08-15 11:01:35 +08:00
Wu Cheng-Han
67474aa1d4 Update realtime check and refresh event, compress data using LZString UTF16 to minimize network delay 2016-08-02 17:16:01 +08:00
Wu Cheng-Han
f69a5361cb Update to make random color more discrete 2016-07-30 11:31:29 +08:00
Wu Cheng-Han
d4804f7aa5 Fix user color is not following the author color 2016-07-30 11:29:03 +08:00
Wu Cheng-Han
a14e7953b5 Add support of showing authorship in editor and adjust related styles 2016-07-30 11:28:24 +08:00
Wu Cheng-Han
2f117a22cd Add support of saving authors and authorship 2016-07-30 11:21:38 +08:00