Isn't this function equivalent to `return "1" if x in args else ""`? (I realize you copied it from the plugin, but I don't understand the purpose of the for loop.)