Skip to content

Commit 2492cf2

Browse files
committed
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>
1 parent bdb8631 commit 2492cf2

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

lib/config/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ if (config.ldap.tlsca) {
5353

5454
// Permission
5555
config.permission = Permission
56-
if (!config.allowAnonymous && !config.allowAnonymousedits) {
56+
if (!config.allowAnonymous && !config.allowAnonymousEdits) {
5757
delete config.permission.freely
5858
}
5959
if (!(config.defaultPermission in config.permission)) {

lib/realtime.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -788,7 +788,7 @@ function connection (socket) {
788788
var note = notes[noteId]
789789
// Only owner can change permission
790790
if (note.owner && note.owner === socket.request.user.id) {
791-
if (permission === 'freely' && !config.allowAnonymous && !config.allowAnonymousedits) return
791+
if (permission === 'freely' && !config.allowAnonymous && !config.allowAnonymousEdits) return
792792
note.permission = permission
793793
models.Note.update({
794794
permission: permission

lib/response.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ function showIndex (req, res, next) {
5959
url: config.serverURL,
6060
useCDN: config.useCDN,
6161
allowAnonymous: config.allowAnonymous,
62-
allowAnonymousEdits: config.allowAnonymousedits,
62+
allowAnonymousEdits: config.allowAnonymousEdits,
6363
facebook: config.isFacebookEnable,
6464
twitter: config.isTwitterEnable,
6565
github: config.isGitHubEnable,
@@ -94,7 +94,7 @@ function responseHackMD (res, note) {
9494
title: title,
9595
useCDN: config.useCDN,
9696
allowAnonymous: config.allowAnonymous,
97-
allowAnonymousEdits: config.allowAnonymousedits,
97+
allowAnonymousEdits: config.allowAnonymousEdits,
9898
facebook: config.isFacebookEnable,
9999
twitter: config.isTwitterEnable,
100100
github: config.isGitHubEnable,

0 commit comments

Comments
 (0)