Fix #4663: Tag script mode sometimes adds "null" tag.
This commit is contained in:
@@ -444,6 +444,7 @@ Post.show_pending_update_notice = function() {
|
||||
}
|
||||
|
||||
Post.tag = function(post_id, tags) {
|
||||
tags ??= "";
|
||||
const tag_string = (Array.isArray(tags) ? tags.join(" ") : String(tags));
|
||||
Post.update(post_id, "tag-script", { post: { old_tag_string: "", tag_string: tag_string }});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user