<commit_before>// Import
var ByteBuffer = require("bytebuffer");


function SetBorder(left, right, top, bottom, gameType, serverName) {
    this.left = left;
    this.right = right;
    this.top = top;
    this.bottom = bottom;
    this.gameType = gameType;
    this.serverName = serverName;
}

module.exports = SetBorder;

SetBorder.prototype.build = function(protocol) {
    var buffer = new ByteBuffer();
    buffer.LE(true);
    buffer.writeUInt8(0x40);
    buffer.writeDouble(this.left);
    buffer.writeDouble(this.top);
    buffer.writeDouble(this.right);
    buffer.writeDouble(this.bottom);
    if (typeof this.gameType != "undefined") {
        buffer.writeUInt32(this.gameType >> 0);
        var name = this.serverName;
        if (typeof name == "undefined" || name == null) {
            name = "";
        }
        buffer.writeUTF8String(name);
        buffer.writeByte(0);
    }
    return buffer.buffer.slice(0, buffer.offset);
};<commit_msg>Add some checks for SetBorder<commit_after>// Import
var ByteBuffer = require("bytebuffer");


function SetBorder(left, right, top, bottom, gameType, serverName) {
    this.left = left;
    this.right = right;
    this.top = top;
    this.bottom = bottom;
    this.gameType = gameType;
    this.serverName = serverName;
}

module.exports = SetBorder;

SetBorder.prototype.build = function(protocol) {
    var buffer = new ByteBuffer();
    buffer.LE(true);
    buffer.writeUInt8(0x40);
    buffer.writeDouble(this.left);
    buffer.writeDouble(this.top);
    buffer.writeDouble(this.right);
    buffer.writeDouble(this.bottom);
    if (typeof this.gameType != "undefined" && this.gameType != null) {
        buffer.writeUInt32(this.gameType >> 0);
        var name = this.serverName;
        if (typeof name == "undefined" || name == null) {
            name = "";
        }
        buffer.writeUTF8String(name);
        buffer.writeByte(0);
    }
    return buffer.buffer.slice(0, buffer.offset);
};
{'fraction_non_alphanumeric': 0.1362940275650842, 'fraction_numerical': 0.010209290454313425, 'mean_word_length': 2.967611336032389, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1272504', 'n_tokens_mistral': 610, 'n_tokens_neox': 601, 'n_words': 124}