Reverted some changes and minor changes