forgot to pass tod var (debug bugfix)