aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMasataka Pocke Kuwabara <kuwabara@pocke.me>2019-12-09 00:48:13 +0900
committer卜部昌平 <shyouhei@ruby-lang.org>2019-12-17 14:14:54 +0900
commit8f52604b478fee5243080116b8e62f0c1f5cb9a0 (patch)
tree5684fd8ecb3452650f8058dc1f23bb004ec398d9
parent9421c7804191b73aa9fde8f14235b3a1f37ffd4b (diff)
downloadruby-8f52604b478fee5243080116b8e62f0c1f5cb9a0.tar.gz
Remove unnecessary double bangs from Pathname#root?
-rw-r--r--ext/pathname/lib/pathname.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/pathname/lib/pathname.rb b/ext/pathname/lib/pathname.rb
index 2fd0642e14..dc4a7c0220 100644
--- a/ext/pathname/lib/pathname.rb
+++ b/ext/pathname/lib/pathname.rb
@@ -207,7 +207,7 @@ class Pathname
# pathnames which points to roots such as <tt>/usr/..</tt>.
#
def root?
- !!(chop_basename(@path) == nil && /#{SEPARATOR_PAT}/o.match?(@path))
+ chop_basename(@path) == nil && /#{SEPARATOR_PAT}/o.match?(@path)
end
# Predicate method for testing whether a path is absolute.