Added more error log details and checking blank parameters