openc3-cosmos-cmd-tlm-api/app/models/streaming_object_collection.rb
Method remove
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
def remove(object)
@mutex.synchronize do
found_object = @objects_by_id[object.id]
if found_object
@objects.delete(found_object)
Avoid deeply nested control flow statements. Open
Open
if packet_objects.length == 0
# Nothing left in either for this topic
@topics_and_offsets.delete(object.topic)
end