angular 4 check if object is empty