Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
ziqian zhang
Grasscutter
Commits
0c665d94
Commit
0c665d94
authored
Apr 28, 2022
by
memetrollsXD
Committed by
Melledy
Apr 27, 2022
Browse files
Add default permissions
parent
f6db3992
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/main/java/emu/grasscutter/Config.java
View file @
0c665d94
...
...
@@ -33,6 +33,7 @@ public final class Config {
public
Boolean
FrontHTTPS
=
true
;
public
boolean
AutomaticallyCreateAccounts
=
false
;
public
String
[]
defaultPermissions
=
new
String
[]
{
""
};
public
RegionInfo
[]
GameServers
=
{};
...
...
src/main/java/emu/grasscutter/server/dispatch/DispatchServer.java
View file @
0c665d94
...
...
@@ -339,6 +339,10 @@ public final class DispatchServer {
// added.
account
=
DatabaseHelper
.
createAccountWithId
(
requestData
.
account
,
0
);
for
(
String
permission
:
Grasscutter
.
getConfig
().
getDispatchOptions
().
defaultPermissions
)
{
account
.
addPermission
(
permission
);
}
if
(
account
!=
null
)
{
responseData
.
message
=
"OK"
;
responseData
.
data
.
account
.
uid
=
account
.
getId
();
...
...
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