fix a syntax error in process_with_transfer

an error of ternary operator.
wrong: a : b ? c
right: a ? b : c