Back end: Refactored context usage. Resolves #139.
Back end: Implemented database row updating functionality if the object already exists on insertion. Resolves #140.
Refactored and sanitized SQLite queries. #108, #118.
Back end: Fixed app crashing on reopening.