Skip to content

Character Creation silently fails #154

@biorisk2

Description

@biorisk2

Found a small bug with a fast fix.

When creating factions, if your faction name is exceedingly long, over 24 characters AFTER trimming, the SQL will silently fail as it is too big for the table's varchar(24).

Servers can patch this by modifying the SQL table from varchar(24) to varchar(255) or greater.

The fix for this is made in https://github.com/NutScript/NutScript/blob/1.2/gamemode/core/libs/sv_database.lua

by changing line 367 from
_faction VARCHAR(24) DEFAULT NULL COLLATE 'utf8mb4_general_ci',

to the following:
_faction VARCHAR(255) DEFAULT NULL COLLATE 'utf8mb4_general_ci',

Huzzah!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions