Fixed logindb_close to use the new struct
Fixed logindb_close to use the new struct