Skip to content

Commit 75144be

Browse files
committed
fix(targetticket): set location may fail
1 parent 1b141a3 commit 75144be

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

inc/targetticket.class.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -977,8 +977,10 @@ protected function setTargetLocation($data, $formanswer) {
977977
'plugin_formcreator_questions_id' => $this->fields['location_question']
978978
]
979979
])->current();
980-
if (isset($location['answer']) && ctype_digit($location['answer'])) {
980+
if (isset($location['answer']) && !Location::isNewID($location['answer'])) {
981981
$location = $location['answer'];
982+
} else {
983+
$location = null;
982984
}
983985
break;
984986
case self::LOCATION_RULE_SPECIFIC:

0 commit comments

Comments
 (0)