fixed erroneous Count of -1 for empty dictionaries