updated w/ Twistle's changes