Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possible bug in admin generator for code/autogen/coldefs.h #79

Open
Daedalus11069 opened this issue Dec 21, 2019 · 0 comments
Open

Possible bug in admin generator for code/autogen/coldefs.h #79

Daedalus11069 opened this issue Dec 21, 2019 · 0 comments

Comments

@Daedalus11069
Copy link
Contributor

During creation of the Utilities controller, I came upon a problem; the bans table in rift_core was not created during the original admin interface, meaning it wasn't accounted for in the generation portion of that interface for generating the code/autogen/coldefs.h file.

The specific problem plaguing that generation script is that there was no cast type for the datetime field type.

So I implemented a slight hack on line 378 of the genColDefs() method of the Utilities controller:

} elseif (
	$f_type === "string" ||
	$f_type === "blob" ||
	$f_type === 'datetime' // FIXME: Fix this hack please
) {
	$m_var .= "tvar{$pchar}{$f_name}.NoDeallocSetTo(row[{$d_name}]);";
}

In short, I cast the datetime field to a string. I don't know if this will have problems later down the line, so here's the bug report to keep track of it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant