Conditional renaming based on spokenlanguage

All about user-defined episode / movie format expressions
Post Reply
Triden
Posts: 2
Joined: 18 Jan 2022, 11:23

Conditional renaming based on spokenlanguage

Post by Triden »

Hey

Love this product but i cant figure out how do do this:

Code: Select all

{audioLanguages.equals([swe]) ? 'SwedishText' : null}
also tried

Code: Select all

{audioLanguages == [swe] ? 'SwedishText' : null}
Does it have something to do with it returning an array?
p.s im no coder
User avatar
rednoah
The Source
Posts: 20839
Joined: 16 Nov 2011, 08:59

Re: Conditional renaming based on spokenlanguage

Post by rednoah »

e.g.

Code: Select all

{ audioLanguages =~ /swe/ ? 'SwedishText' : null }
:idea: Please read the FAQ and How to Request Help.
Triden
Posts: 2
Joined: 18 Jan 2022, 11:23

Re: Conditional renaming based on spokenlanguage

Post by Triden »

Yes, it works. Thanks a lot!
Post Reply