rewrote to use labels