Fix core.php
Close #058.