impoved handling of defualt variables