added in null checks for request params