Revamp this function to be more flexible
Revamp this function to be more flexible

skypies/flightdb,skypies/flightdb,skypies/flightdb2,skypies/flightdb,skypies/flightdb2,skypies/flightdb,skypies/flightdb2