Miner fixing

Condition statement enhancement and completed more comment