Possibly unintended behavior when a tag contains <crlf>
Posted: 21 Aug 2024 22:18
This is easily remedied just by running
I use a script to tag items, then I have a couple db's that store their own tag clouds. Before I realized I had a trailing <crlf> in my tag, this is what happened:
-My script would tag the items properly
-When I switched tag cloud to db2,
-When switching back to db1
-Switching away would save the current empty taglist to db1, overwriting the previous entries, resulting in those tags being lost
There's a warning pop-up when trying to pass a " into the tags, and I was wondering if something similar shouldn't be done for <crlf>? It's an invisible character and it could take a bit to figure out that it's causing issues.
replacelist($string, <crlf>, ""), but I'm not sure if the consequences of having a <crlf> slip into the tags is intended.I use a script to tag items, then I have a couple db's that store their own tag clouds. Before I realized I had a trailing <crlf> in my tag, this is what happened:
-My script would tag the items properly
-When I switched tag cloud to db2,
tagexport() saved the tags properly to db1-When switching back to db1
tagload() just wouldn't load anything from db1, resulting in an empty tag list-Switching away would save the current empty taglist to db1, overwriting the previous entries, resulting in those tags being lost
There's a warning pop-up when trying to pass a " into the tags, and I was wondering if something similar shouldn't be done for <crlf>? It's an invisible character and it could take a bit to figure out that it's causing issues.