Js block with multiple outputs

I’m trying to set 2 page variables from a JS block

My JS block supposed to have 3 outputs; output3 for ERRORS and output1 & output2 are to set 2 different page variables whenever a certain if statement is true.

The problem i’m having is that the program terminates itself as soon as if statement is true and the 1st output is returned.
It is basically skipping the rest of the code after returning the 1st output therefore the 2nd output is not returned at all.

Both output1& output2 are ok. I tried exchanging their positions in the code and in each time the 1st output in the code works just fine and sets its relevant page variable

Any ideas?