[MIRROR] Uses regex datums and macros for text-manipulation (#7805)

* Uses regex datums and macros for text-manipulation (#61042)

* Uses regex datums and macros for text-manipulation

* a

Co-authored-by: Rohesie <rohesie@gmail.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
This commit is contained in:
SkyratBot
2021-09-01 16:28:56 +01:00
committed by GitHub
co-authored by Rohesie Gandalf
parent 8da357aca4
commit 9290399403
9 changed files with 71 additions and 74 deletions
+2 -2
View File
@@ -260,7 +260,7 @@ GLOBAL_LIST_EMPTY(asset_datums)
var/item_filename
/datum/asset/changelog_item/New(date)
item_filename = sanitize_filename("[date].yml")
item_filename = SANITIZE_FILENAME("[date].yml")
SSassets.transport.register_asset(item_filename, file("html/changelogs/archive/" + item_filename))
/datum/asset/changelog_item/send(client)
@@ -301,7 +301,7 @@ GLOBAL_LIST_EMPTY(asset_datums)
continue
asset = fcopy_rsc(asset) //dedupe
var/prefix2 = (directions.len > 1) ? "[dir2text(direction)]." : ""
var/asset_name = sanitize_filename("[prefix].[prefix2][icon_state_name].png")
var/asset_name = SANITIZE_FILENAME("[prefix].[prefix2][icon_state_name].png")
if (generic_icon_names)
asset_name = "[generate_asset_name(asset)].png"