Telegram-iOS icon indicating copy to clipboard operation
Telegram-iOS copied to clipboard

What is !"".isEmpty?

Open whyamsx opened this issue 1 year ago • 1 comments

Checklist

  • [ ] I am reporting an issue in existing functionality that does not work as intended
  • [x] I've searched for existing GitHub issues

Description

This is not the first time I have seen conditions like this in the source code: "".isEmpty or !"".isEmpty (example here). Help me understand what this means and what it is for?

Yes, I created this question here because otherwise this secret cannot be solved.

Expected Behavior

At least something logical *literally at this moment I felt cognitive dissonance*

Actual Behavior

Obviously something is weird because this condition cannot be variable, the same as writing true or false.

whyamsx avatar Nov 25 '24 20:11 whyamsx

hi

sreynan75 avatar Nov 26 '24 09:11 sreynan75