summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/gitlab/string_path.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/gitlab/string_path.rb b/lib/gitlab/string_path.rb
index 4d024b3ff73..a6234d34e7d 100644
--- a/lib/gitlab/string_path.rb
+++ b/lib/gitlab/string_path.rb
@@ -19,6 +19,10 @@ module Gitlab
@path
end
+ def exists?
+ @path == './' || @universe.include?(@path)
+ end
+
def absolute?
@path.start_with?('/')
end