Changed order of initialization and calling the set target and id method so that things work