better handling of empty vars