Fix 8.1 errors. Fix #4.

Bugfixs for 8.1