Fixed bug for passing model and dbrefresh.