Why we don't define self.hazard = hazard and then we can extract the id with self.hazard.id?