If actor(x) is in party

I have been developing an idea in my head for a game with a turn-based tactical battle system.
I've made a lot of progress with the system using the built in events, script calls, and a few plugins, and now I'm trying to condense the code so it is easier to bug fix.
Attached is a picture of some code that is designed to check if an actor is in the party, and if so, allow the player to control him in the battle system.
My current code gets the error 'Syntax Error Unexpected token )'
I got the code in the if statement from here.
https://forums.rpgmakerweb.com/index.php?threads/check-if-an-actor-is-in-party.69879/

Did I make a mistake with my code? Or is there a different way that I need to check if an actor is in the party?
http://esprima.org/demo/validate.html
Yes, a syntax error means you made a typing error in your code.

Just FYI, in the future, it's more helpful if you paste your code inside a CODE box on the forum so we can copy/paste your code into an editor to quickly check it. (Use the "Insert..." button then "Code".)

It looks like you have an extra closing parenthesis on line 8 and another on line 9.

It also looks like you're using the correct script call, but let us know if it still doesn't work after fixing your syntax and we can take a closer look.
You guys respond really quickly. Thank you.
You are correct the parenthesis on line 8 and 9 were the issue. I thought it was an issue in the if statement.

I'll bookmark the code editor so I can use it again later.
Thank you so much for the help.
Thread closed IgnoreMe

Original thread: https://forums.rpgmakerweb.com/threads/if-actor-x-is-in-party.89739/