Added error cases to stmt block and fixed an error in get function