fixed bug in union code with new bs