Added logic for creating new tracking code