Adding some coding improvements