fix save error when project is null