added condition if staging or production mode