Fixed searchQuery algorithm, added to DevelopmentNotes