| Auto-Submit | +1 |
const intptr_t zone_id = free_service_id_zone_slots_->Last();Nourhan HasanI don't think this is the right solution here, mainly because reusing IDs makes it easier for clients to accidentally delete ID zones using an old ID when the zone has already been reused.
The right solution would be to use a map of ID zone IDs -> ID zones instead of a growable array so that we can remove entries as zones are cleaned up.
Nourhan HasanThanks for the feedback. I hadn't considered this case. I chose the free list approach because it requires minimal changes and retains O(1) operations while keeping the array size bounded. However, I agree that using the map would be safer and more effective, but it would require more changes, I think, so I'll see how I can implement that.
Done
| Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |