Fixed the search bug in the user interface, added tests and populate to
flight class