This is the main functionality addition to the script