Fixed some minor issues in the register module
Fixed issue in index.php