Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wiki-js
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
wiki-js
Commits
c57c9d90
Commit
c57c9d90
authored
Mar 25, 2021
by
NGPixel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: disable cors
parent
05aad5b9
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
servers.js
server/core/servers.js
+1
-1
master.js
server/master.js
+2
-2
No files found.
server/core/servers.js
View file @
c57c9d90
...
...
@@ -130,7 +130,7 @@ module.exports = {
path
:
'/graphql-subscriptions'
}
})
this
.
servers
.
graph
.
applyMiddleware
({
app
:
WIKI
.
app
})
this
.
servers
.
graph
.
applyMiddleware
({
app
:
WIKI
.
app
,
cors
:
false
})
},
/**
* Close all active connections
...
...
server/master.js
View file @
c57c9d90
...
...
@@ -42,8 +42,8 @@ module.exports = async () => {
// ----------------------------------------
app
.
use
(
mw
.
security
)
app
.
use
(
cors
(
WIKI
.
config
.
cors
))
app
.
options
(
'*'
,
cors
(
WIKI
.
config
.
cors
))
app
.
use
(
cors
(
{
origin
:
false
}
))
app
.
options
(
'*'
,
cors
(
{
origin
:
false
}
))
if
(
WIKI
.
config
.
security
.
securityTrustProxy
)
{
app
.
enable
(
'trust proxy'
)
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment