fix [FCModel databaseIsOpen]

Hello Marco, 
this was giving me an incorrect answer in some cases, probably because (BOOL) incorrectly truncates the pointer.

I wanted to add some tests, but I noticed that there already exists a test in -testDatabaseCloseFlushesCache for -databaseIsOpen, and I'm not sure having more tests would make sense.

Thanks, Ilya.