Skip to content

Commit a2c240b

Browse files
authored
Merge pull request #1076 from lshqqytiger/banfix1
차단 기능의 버그 해결
2 parents 9552e33 + 7400d0c commit a2c240b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Server/lib/Game/slave.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ Server.on('connection', function(socket, info){
137137
$c.remoteAddress = GLOBAL.USER_BLOCK_OPTIONS.USE_X_FORWARDED_FOR ? info.connection.remoteAddress : (info.headers['x-forwarded-for'] || info.connection.remoteAddress);
138138
if(GLOBAL.USER_BLOCK_OPTIONS.USE_MODULE && ((GLOBAL.USER_BLOCK_OPTIONS.BLOCK_IP_ONLY_FOR_GUEST && $c.guest) || !GLOBAL.USER_BLOCK_OPTIONS.BLOCK_IP_ONLY_FOR_GUEST)){
139139
MainDB.ip_block.findOne([ '_id', $c.remoteAddress ]).on(function($body){
140-
if ($body.reasonBlocked) {
140+
if ($body && $body.reasonBlocked) {
141141
$c.socket.send(JSON.stringify({
142142
type: 'error',
143143
code: 446,

0 commit comments

Comments
 (0)