Added constructor code