Trying to figure out register bugs