in place of "olines," you could put
$iif(%olinecount == 1,oline,olines) $+ ,
Then it will update from olines to oline if you have one oline and not 2.