Mining shit improvements.

Redmine #68
Redmine #69