Fixed bug in minelib