Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
S
srvpro
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
1
Issues
1
List
Boards
Labels
Service Desk
Milestones
Merge Requests
3
Merge Requests
3
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
srvpro
Commits
fb77d7de
Commit
fb77d7de
authored
Oct 21, 2021
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix ban get
parent
fdec62ea
Pipeline
#6348
failed with stages
in 29 minutes and 43 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
20 deletions
+18
-20
ygopro-server.coffee
ygopro-server.coffee
+6
-6
ygopro-server.js
ygopro-server.js
+12
-14
No files found.
ygopro-server.coffee
View file @
fb77d7de
...
...
@@ -2121,16 +2121,16 @@ ygopro.ctos_follow 'JOIN_GAME', true, (buffer, info, client, server, datas)->
return
if
settings
.
modules
.
mycard
.
enabled
and
settings
.
modules
.
mycard
.
ban_get
and
!
client
.
is_local
try
banMCRequest
=
await
axios
.
get
settings
.
modules
.
mycard
.
ban_get
,
paramsSerializer
:
qs
.
stringify
params
:
user
:
client
.
name
axios
.
get
settings
.
modules
.
mycard
.
ban_get
,
paramsSerializer
:
qs
.
stringify
params
:
user
:
client
.
name
.
then
(
banMCRequest
)
->
if
typeof
(
banMCRequest
.
data
)
==
"object"
client
.
ban_mc
=
banMCRequest
.
data
else
log
.
warn
"ban get bad json"
,
banMCRequest
.
data
catch
e
.
catch
(
e
)
->
log
.
warn
'ban get error'
,
e
.
toString
()
check_buffer_indentity
=
(
buf
)
->
...
...
ygopro-server.js
View file @
fb77d7de
...
...
@@ -2728,7 +2728,7 @@
});
ygopro
.
ctos_follow
(
'
JOIN_GAME
'
,
true
,
async
function
(
buffer
,
info
,
client
,
server
,
datas
)
{
var
available_logs
,
banMCRequest
,
check_buffer_indentity
,
create_room_with_action
,
duelLog
,
e
,
exactBan
,
index
,
j
,
l
,
len
,
len1
,
pre_room
,
recover_match
,
replay
,
replay_id
,
replays
,
room
,
struct
;
var
available_logs
,
check_buffer_indentity
,
create_room_with_action
,
duelLog
,
exactBan
,
index
,
j
,
l
,
len
,
len1
,
pre_room
,
recover_match
,
replay
,
replay_id
,
replays
,
room
,
struct
;
//log.info info
info
.
pass
=
info
.
pass
.
trim
();
client
.
pass
=
info
.
pass
;
...
...
@@ -2809,22 +2809,20 @@
return
;
}
if
(
settings
.
modules
.
mycard
.
enabled
&&
settings
.
modules
.
mycard
.
ban_get
&&
!
client
.
is_local
)
{
try
{
banMCRequest
=
(
await
axios
.
get
(
settings
.
modules
.
mycard
.
ban_get
,
{
paramsSerializer
:
qs
.
stringify
,
params
:
{
user
:
client
.
name
}
}));
axios
.
get
(
settings
.
modules
.
mycard
.
ban_get
,
{
paramsSerializer
:
qs
.
stringify
,
params
:
{
user
:
client
.
name
}
}).
then
(
function
(
banMCRequest
)
{
if
(
typeof
banMCRequest
.
data
===
"
object
"
)
{
client
.
ban_mc
=
banMCRequest
.
data
;
return
client
.
ban_mc
=
banMCRequest
.
data
;
}
else
{
log
.
warn
(
"
ban get bad json
"
,
banMCRequest
.
data
);
return
log
.
warn
(
"
ban get bad json
"
,
banMCRequest
.
data
);
}
}
catch
(
error1
)
{
e
=
error1
;
log
.
warn
(
'
ban get error
'
,
e
.
toString
());
}
}).
catch
(
function
(
e
)
{
return
log
.
warn
(
'
ban get error
'
,
e
.
toString
());
});
}
check_buffer_indentity
=
function
(
buf
)
{
var
checksum
,
i
,
m
,
ref
;
...
...
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