GET requests are working but POST requests have undefinied data