Adding input check for AP and Donation

Fixes #354
Merge pull request #365 from TheSerapher/issue-354

Adding input check for AP and Donation