fix minor bug empty != nil