You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Test code is still in master and there are no specs.
Also, objects are serialized by hand instead of using the MTL-serialization that we actually get for free.
Also, we are generating our own ID, which should be done by the database. Additionally: we're doing multiple queries to check that we didn't select an existing ID.
Also, we're building the query using NSString stringWithFormat, which isn't correct. We should use executeQuery: withParametersInArray or executeQuery: withParameterDictionary, from FMDatabase.
Preferrably, model classes should construct their own update queries, rather than having this hardcoded into OPFUpdateQuery.
Tasks
Important
Remove test code form actual classes
Write specs
Use safe method of inserting query values
Use db to generate IDs
Optional
Use MTL-serialization
Refactor class-specific update queries to the responsible model class
The text was updated successfully, but these errors were encountered:
@jesjos Cool 👍 I guess you haven't pushed it to master yet, but I will clean up OPFUpdateQuery later, because just now it looks terrible and has many inconsistencies. The reason for the messiness is some debugging I did yesterday.
I just pushed fixes for safe insertion and id-generation. As we said earlier, the db isn't configured correctly, so we have to do a separate query to find the next id :/
Issues:
Test code is still in master and there are no specs.
Also, objects are serialized by hand instead of using the MTL-serialization that we actually get for free.
Also, we are generating our own ID, which should be done by the database. Additionally: we're doing multiple queries to check that we didn't select an existing ID.
Also, we're building the query using
NSString stringWithFormat
, which isn't correct. We should useexecuteQuery: withParametersInArray
orexecuteQuery: withParameterDictionary
, fromFMDatabase
.Preferrably, model classes should construct their own update queries, rather than having this hardcoded into
OPFUpdateQuery
.Tasks
Important
Optional
The text was updated successfully, but these errors were encountered: