Touch sensor is bugging when used 2 if statement

I'm using a touch sensor to use for if statements but when used two if statement it doesn't work, it starts printing "right" from time to time without me even touching as intended but printing "left" works fine when touched or vice versa. It works when when i only use one touch sensor in one if statement. how to solve this or is something wrong in my code?

code here:
''''''''''
#define touchpin1 T8
#define touchpin2 T9

int touchvalue1;
int touchvalue2;

const int threshold = 10;

void setup() {
Serial.begin(115200);
delay(1000);
}

void loop() {

touchvalue1 = touchRead(touchpin1);
touchvalue2 - touchRead(touchpin2);

Serial.println(touchvalue1);
Serial.println(touchvalue2);

if (touchvalue1 < threshold) {
Serial.println("left");
delay(500);
}

if (touchvalue2 < threshold) {
Serial.println("right");
delay(500);
}
}
''''''''

output here:
Screenshot 2022-11-21 025847

Welcome. Both your code and output are improperly posted. Please read:

You left out other details, too. Like, what board you are using.

Where are T8 and T9 defined? Those are not standard pin numbers on any Arduino I know of. Thus, I suspect maybe you didn't post the entire sketch.

Welcome,

Don't you see a mistake in the second line ?

touchvalue1 = touchRead(touchpin1);
touchvalue2 - touchRead(touchpin2);