Hi @Tarun Sharma ,
Welcome to Microsoft Q&A forum and thanks for reaching out here.
Why If activity expression is resulting in False?
The reason always the IF condition enters false path is because as per your dynamic expression (@contains(activity('Get Metadata1').output.childItems,'SalesLT.Customer.txt' )) , you are passing @activity('Get Metadata1').output.childItems which is an array type to @contains function. But @contains() function expects a string as input argument and then looks for provided substring exits or not. This is the reason why it always enters false path.
Resolution: In order to convert the array type to string you can use @String() function and it should help convert your childItems from array to a string type.
To do so please use below dynamic expression and it should help resolve your issue.
@contains(string(activity('Get Metadata1').output.childItems),'SalesLT.Customer.txt' )
Hope this helps.
Please don’t forget to Accept Answer and Yes for "was this answer helpful" wherever the information provided helps you, this can be beneficial to other community members.