Update minting.php, some more error fixes.