Added database and history functions, things record now
Merge remote-tracking branch 'origin/master'