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
119555bd
Commit
119555bd
authored
May 27, 2016
by
mercury233
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix return
parent
798f67cf
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
5 deletions
+10
-5
.gitignore
.gitignore
+1
-0
ygopro-server.coffee
ygopro-server.coffee
+5
-1
ygopro-server.js
ygopro-server.js
+4
-4
No files found.
.gitignore
View file @
119555bd
...
@@ -6,6 +6,7 @@ password.json
...
@@ -6,6 +6,7 @@ password.json
config.*.json
config.*.json
ygopro
ygopro
windbot
/node_modules/
/node_modules/
!/node_modules/struct/
!/node_modules/struct/
...
...
ygopro-server.coffee
View file @
119555bd
...
@@ -744,7 +744,8 @@ ygopro.ctos_follow 'JOIN_GAME', false, (buffer, info, client, server)->
...
@@ -744,7 +744,8 @@ ygopro.ctos_follow 'JOIN_GAME', false, (buffer, info, client, server)->
msg
:
1
msg
:
1
code
:
2
code
:
2
}
}
client
.
end
()),
500
client
.
end
()
return
),
500
else
if
info
.
pass
[
0
...
2
].
toUpperCase
()
==
"R#"
and
settings
.
modules
.
enable_cloud_replay
else
if
info
.
pass
[
0
...
2
].
toUpperCase
()
==
"R#"
and
settings
.
modules
.
enable_cloud_replay
replay_id
=
info
.
pass
.
split
(
"#"
)[
1
]
replay_id
=
info
.
pass
.
split
(
"#"
)[
1
]
...
@@ -972,6 +973,7 @@ ygopro.stoc_follow 'JOIN_GAME', false, (buffer, info, client, server)->
...
@@ -972,6 +973,7 @@ ygopro.stoc_follow 'JOIN_GAME', false, (buffer, info, client, server)->
room
=
ROOM_all
[
client
.
rid
]
room
=
ROOM_all
[
client
.
rid
]
return
unless
room
and
settings
.
modules
.
enable_cloud_replay
return
unless
room
and
settings
.
modules
.
enable_cloud_replay
room
.
recorder_buffers
.
push
data
room
.
recorder_buffers
.
push
data
return
recorder
.
on
'error'
,
(
error
)
->
recorder
.
on
'error'
,
(
error
)
->
return
return
...
@@ -1176,6 +1178,8 @@ if settings.modules.mycard_auth and process.env.MYCARD_AUTH_DATABASE
...
@@ -1176,6 +1178,8 @@ if settings.modules.mycard_auth and process.env.MYCARD_AUTH_DATABASE
for
row
in
result
.
rows
for
row
in
result
.
rows
users_cache
[
row
.
username
]
=
row
.
id
users_cache
[
row
.
username
]
=
row
.
id
console
.
log
(
"users loaded"
,
_
.
keys
(
users_cache
).
length
)
console
.
log
(
"users loaded"
,
_
.
keys
(
users_cache
).
length
)
return
return
ygopro
.
stoc_follow
'DUEL_START'
,
false
,
(
buffer
,
info
,
client
,
server
)
->
ygopro
.
stoc_follow
'DUEL_START'
,
false
,
(
buffer
,
info
,
client
,
server
)
->
room
=
ROOM_all
[
client
.
rid
]
room
=
ROOM_all
[
client
.
rid
]
...
...
ygopro-server.js
View file @
119555bd
...
@@ -931,7 +931,7 @@
...
@@ -931,7 +931,7 @@
msg
:
1
,
msg
:
1
,
code
:
2
code
:
2
});
});
return
client
.
end
();
client
.
end
();
}),
500
);
}),
500
);
}
else
if
(
info
.
pass
.
slice
(
0
,
2
).
toUpperCase
()
===
"
R#
"
&&
settings
.
modules
.
enable_cloud_replay
)
{
}
else
if
(
info
.
pass
.
slice
(
0
,
2
).
toUpperCase
()
===
"
R#
"
&&
settings
.
modules
.
enable_cloud_replay
)
{
replay_id
=
info
.
pass
.
split
(
"
#
"
)[
1
];
replay_id
=
info
.
pass
.
split
(
"
#
"
)[
1
];
...
@@ -1172,7 +1172,7 @@
...
@@ -1172,7 +1172,7 @@
if
(
!
(
room
&&
settings
.
modules
.
enable_cloud_replay
))
{
if
(
!
(
room
&&
settings
.
modules
.
enable_cloud_replay
))
{
return
;
return
;
}
}
r
eturn
r
oom
.
recorder_buffers
.
push
(
data
);
room
.
recorder_buffers
.
push
(
data
);
});
});
recorder
.
on
(
'
error
'
,
function
(
error
)
{});
recorder
.
on
(
'
error
'
,
function
(
error
)
{});
}
}
...
@@ -1431,7 +1431,7 @@
...
@@ -1431,7 +1431,7 @@
if
(
error
)
{
if
(
error
)
{
throw
error
;
throw
error
;
}
}
return
client
.
query
(
'
SELECT username, id from users
'
,
function
(
error
,
result
)
{
client
.
query
(
'
SELECT username, id from users
'
,
function
(
error
,
result
)
{
var
k
,
len
,
ref
,
row
;
var
k
,
len
,
ref
,
row
;
if
(
error
)
{
if
(
error
)
{
throw
error
;
throw
error
;
...
@@ -1442,7 +1442,7 @@
...
@@ -1442,7 +1442,7 @@
row
=
ref
[
k
];
row
=
ref
[
k
];
users_cache
[
row
.
username
]
=
row
.
id
;
users_cache
[
row
.
username
]
=
row
.
id
;
}
}
return
console
.
log
(
"
users loaded
"
,
_
.
keys
(
users_cache
).
length
);
console
.
log
(
"
users loaded
"
,
_
.
keys
(
users_cache
).
length
);
});
});
});
});
}
}
...
...
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