* Avoid lodash typecheks
Lodash is quite big project. Even with direct imports it loads [tons](https://github.com/knex/knex/pull/3804) of
code and still bloats node_modules. Especially since lodash mostly used
as a polyfill for modern features.
In this diff I attempted to reduce lodash usage by replacing type checks
with `typeof` operator which might be sufficient.
Also replaced lodash/isObject with custom simplified utility which does not
consider functions as objects and allows to simplify code in one place.
Returns 0 if all migrations are run and DB is up to date. Return negative number if DB is missing migrations. Return positive number if DB is ahead (rare case, e.g. if migrations were run then code is reverted)
Beefed up transaction implementation, still needs tests
and cleanup of nested transaction queues.
Left todo:
- Fix commented out tests
- Fix oracle driver's transactions