Commit graph

56 commits

Author SHA1 Message Date
Sakura Akeno Isayeki
4c13084eb3
fix(db): Fix casing for regions and warps 2025-04-29 02:05:51 +02:00
Sakura Akeno Isayeki
2d839e3609
fix(db/postgres): Resolve SQL identifier casing issues
Improves SQL query execution by ensuring proper casing for identifiers across various database types, particularly for Postgres.

Enhances security and compatibility by using an identifier escaping method, preventing potential errors due to case sensitivity in SQL queries.

Addresses potential issues with existing queries for better reliability and consistency.
2025-04-29 00:47:19 +02:00
Sakura Akeno Isayeki
084411f847
refactor(db): Update SqlQueryBuilder references + Various refactors
Consolidates the creation of SQL query builders across multiple classes to ensure a unified approach for database operations.

Replaces manual type checks and specific query creators with a generic method for better maintainability and to prevent errors.

Improves code readability and reduces duplication, facilitating easier updates in the future.
2025-04-28 15:51:26 +02:00
Sakura Akeno Isayeki
8a75b1fdc5
refactor(db): Move DbQueryBuilders to separate namespace
Removes obsolete query builder interface and implementations.

Introduces a new namespace for query-related classes to enhance organization.

Updates various database managers to use the new query utilities, promoting code reuse and maintainability.

Enhances query functionality, ensuring better consistency across the codebase.
2025-04-28 14:06:02 +02:00
Killia0
154bee58f1 Typo fixes on comments/strings
My first PR contribution to TShock is spellcheck huh, frankly I don't know why but hey I could spare the time for this and caught some stuff.
2021-07-16 14:53:37 -04:00
Lucas Nicodemus
70dd72443d Update copyright to 2019 again
Fixes #1658, most likely.
2019-03-29 17:16:37 -07:00
Lucas Nicodemus
569b350cea Update to Pryaxis, 2018 part 2
If there's one thing I learned in this exercise, it's that letting
people add random python scripts to the repo like gpltext.py that
promise to be easier than find and replace is a bad idea.
2018-01-01 02:20:56 -07:00
Ryozuki
587d1b7390 fix comment typo 2017-07-15 13:32:09 -06:00
White
c4a3a9fb67 Updated Copyright for 2017 2017-03-13 12:17:16 +10:30
Lucas Nicodemus
678f6c7cf8
Update to Mintaka (thanks @enerdy) 2016-12-06 17:36:44 -07:00
Lucas Nicodemus
a0c4864567
Removed all obsolete methods from TShock 2016-10-23 06:09:17 -06:00
Adilson Carvalho
49b4effe74 Changed year to 2016 on all GPL headers 2016-10-16 17:06:02 -02:00
Lucas Nicodemus
06becadc8d Document Warp() constructor 2015-04-13 01:03:13 -06:00
Lucas Nicodemus
cbce64f1eb Remove more obsolete code; fix tab/space screwup in TSPlayer 2015-02-28 19:37:06 -07:00
Lucas Nicodemus
04145a4aca Re-add EnsureExists signature to fix compat with old plugins
Fixes #862
2015-02-22 08:43:12 -07:00
Zack
f9bf470b1d Tick version and update copyright 2015-01-28 15:29:13 -05:00
Zack Piispanen
d5527ade42 Add length to database primary keys.
Tweak some of the itembans code to be less inefficient.
Removed a chunk of code from the buff code that prevented users from being buffed with a buff that comes from an item.  This code seemed to cause max cpu usage when being disabled.  I don't think this code is useful, but I leave that to people who own servers.  IMO all buff code should be removed.
2014-09-15 09:05:28 -04:00
Zack Piispanen
1c7fe908b6 Delete a bunch of cruft that has gone unmaintained for too long.
Fix warps to have an auto-increment primary key column, and unique on name/WorldID
Same for regions.
Changed SqliteTableCreator to do proper unique syntax.
2014-09-03 02:41:53 -04:00
Zack
fb451c6d49 Update license header for 2014 2014-07-10 21:48:33 -04:00
MarioE
85cf46166a Fix some more plugin-breaking changes 2013-12-18 10:24:17 -05:00
MarioE
766b077e99 Undo plugin-breaking changes 2013-12-15 18:50:44 -05:00
MarioE
3405acd15b Fix warps 2013-11-03 17:10:20 -05:00
MarioE
7e7068294f Er, forgot to initialize list 2013-11-01 23:57:22 -04:00
MarioE
41121b8412 Re-do warps 2013-11-01 23:55:31 -04:00
MarioE
3e9aee3414 Begin Raptor compatibility 2013-10-30 22:34:09 -04:00
Lucas Nicodemus
ae7ab5f234 Updated copyright information to point to 2013. 2013-08-22 21:51:17 -06:00
Lucas Nicodemus
8d5cdf04a8 Update copyright to reflect actual year date. 2012-04-24 12:45:46 -06:00
Lucas Nicodemus
bf9d0137f1 Added any missing license headers to all files 2012-01-01 03:06:48 -07:00
Lucas Nicodemus
4e20b87992 Remove flat file conversion code from warp system 2012-01-01 02:51:46 -07:00
Lucas Nicodemus
2bfdaaaabc Remove flat file conversion code 2012-01-01 02:48:15 -07:00
Lucas Nicodemus
c6abbfe4d2 ReSharper code reformat to match naming conventions and stuff 2011-12-30 14:38:04 -07:00
Lucas Nicodemus
1147788154 ReSharper redundant code cleanup 2011-12-30 14:32:05 -07:00
high
b2f47f57ac Updated to new binary (with the api merged).
Removed System.Drawing dependency
2011-09-24 18:30:19 -04:00
Lucas Nicodemus
442a5b4202 Stuff 2011-09-02 23:21:01 -06:00
high
56eca71853 Fixed SCA warnings 2011-08-06 16:49:40 -04:00
high
1a801b268c All managers now use querybuilder for creating tables to make for easy changes. 2011-08-03 19:55:23 -04:00
Twitchy
dd33927e76 Added private/public warps. Todo before release - make warps with spaces hide. (Too tired. Cannot finish) 2011-08-02 23:18:53 +12:00
Lucas Nicodemus
37146adb4c Resharper code cleanup, including:
- Optimized using statements
 - Removal of redundant code
2011-07-26 23:37:06 -06:00
high
e8a5e7fb58 Now uses Query/QueryReader 2011-07-24 12:33:00 -04:00
Lucas Nicodemus
d8e8c5df91 Warps are no longer ToLower()'d. 2011-07-23 01:14:52 -06:00
Lucas Nicodemus
219f5a8cfb WorldIDs 2011-07-22 23:35:21 -06:00
Lucas Nicodemus
870c1f74f4 Fixed warps too 2011-07-22 23:29:41 -06:00
high
1c2cead3c9 Fixed /warp list <page>
ListAllWarps now only returns names and only for the specified world.
2011-07-22 21:36:07 -04:00
Lucas Nicodemus
e1cd87f487 Fixed regions
Added /convert
2011-07-22 17:38:51 -06:00
Lucas Nicodemus
b98614946d Changed every instance of Main.worldID.ToString() to Main.worldName. You broke backwards compatibility with all other warp and region files by doing that. 2011-07-21 15:03:15 -06:00
Zack Piispanen
e5826fbc0a Converts Warps to db files, and fixes a bug in region code.
Currently, the program fails to copy the old xml files to the new directory, so you may want to manually do that.
2011-07-19 19:30:07 -04:00
Lucas Nicodemus
77ed57a4bd PRIMARY KEY, thanks SQLite for being a FUCKING DICKBAG 2011-07-13 02:47:32 -06:00
Lucas Nicodemus
2608ca0779 We want PRIMARY keys, not UNIQUE keys, because UNIQUE without PRIMARY means absolute BULLSHIT. 2011-07-13 02:42:06 -06:00
Twitchy
30d0d48386 Added reader closing (if it will help) and returns default group rather than "null" 2011-07-12 21:16:59 +12:00
Twitchy
b74455433e Changed Exception catch types. Removed trying to insert to ID field 2011-07-12 19:36:17 +12:00