SC-1:fix Null pointer exception