Adding heuristics for returning objects. Adding count saving functionality