Fixed a few bugs

I moved the replyid check inside the loop so that we're always up-to-date with what we've replied to.
Also, I stopped accepting injections as valid input.