fix nil warning