Refactored, and made POST work, basically