bugfixes to digging