Fixed edge case bug
Changed some label handling