bunch of fixes to minting.php
Merge pull request #118 from waynn/patch-3

bunch of fixes to minting.php