DB: Handle nulls in ExecuteScalar
Data: Don't choke on DirectoryManager refresh