Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCarsten Hammer2019-04-06 17:06:58 +0000
committerDavid Pursehouse2019-04-11 02:45:11 +0000
commitbf251ea0e844c1269256845ac032a44a49a9e88a (patch)
tree7c3f50bff88eafdbaed37f0a83f62f82fa0ce196 /org.eclipse.jgit
parentdff4f6cc74d54e28252d9c83cc486bf1c8e26d5b (diff)
downloadjgit-bf251ea0e844c1269256845ac032a44a49a9e88a.tar.gz
jgit-bf251ea0e844c1269256845ac032a44a49a9e88a.tar.xz
jgit-bf251ea0e844c1269256845ac032a44a49a9e88a.zip
Replace usage of String.indexOf with String.contains where possible
Change-Id: Iad3fce891077d85cf2533272c54206c33c37afd8 Signed-off-by: Carsten Hammer <carsten.hammer@t-online.de> Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
Diffstat (limited to 'org.eclipse.jgit')
-rw-r--r--org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java
index 8b41ab0466..9dacaec881 100644
--- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java
+++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java
@@ -779,7 +779,7 @@ public class TransportHttp extends HttpTransport implements WalkTransport,
}
// git allows only rewriting the root, i.e., everything before INFO_REFS
// or the service name
- if (next.indexOf(checkFor) < 0) {
+ if (!next.contains(checkFor)) {
return false;
}
// Basically we should test here that whatever follows INFO_REFS is

Back to the top