The switch function accepts a final fallback value -- should be empty.
Use ifempty() to skip the first switch statement if it is empty -- or first_non_empty() for more than two switches.
No need for recursive test()'s.
The final '' is redundant logic -- you should be relying on the spot reserved by generic_flag.png
Speaking of which those are mutually conflicting goals.
Last edited by eschwartz; 12-30-2015 at 11:19 PM.
|