try to outofscope the temporary model to release the db connection
Merge branch 'hotfix/0.9.13'