I didn't really read this code, but you said it was from the Bird, so I assume it's correct