now only saving changed data onPause, onPause saving of db changes now runs in UI thread again to avoid problems with database references getting closed out of order
resolved merge conflict in MainActivity