Fixed file writing if no entries listed.
Logging in changes.