marcoarment/FCModel — pull request #14 by raylillywhite (2013-10-14 07:51:25+00:00)
Title: SQLCipher with FCModel - I need to prep the db before openDatabase: will work

I have FCModel working great, almost right out of the box, with [SQLCipher](http://sqlcipher.net/). I just have to run either `sqlite3_key(db.sqliteHandle, key, strlen(key));` or `[db executeUpdate:@"PRAGMA key = 'passphrase'"];` before FCModel attempts to read from its model metadata table.

It seemed that the cleanest and most general way to do that was to add an initializer block that is run before FCModel does anything with the database. I'm not sure if this would be useful for any other cases though, so let me know if you can think of way that I could refactor this that might be simpler or more useful.