revert some codes