Mechanical change in webkitpy: x.find(y) != -1 => y in x
Also x.find(y) == -1 => y not in x
Reason: I believe that they're equivalent and the version using "in" is more readable.
This was done using:
find . -name '*.py' -exec sed -i -f ~/find.sed {} +
Where ~/find.sed contains:
# Match short strings inside parens to avoid false positives (not foolproof)
s/\(\w\+\)\.find(\(.\{1,10\}\)) != -1/\2 in \1/
s/\(\w\+\)\.find(\(.\{1,10\}\)) == -1/\2 not in \1/
Review-Url: https://codereview.chromium.org/1999533002
Cr-Commit-Position: refs/heads/master@{#395503}
8 files changed