diff options
author | Conrad Irwin <conrad.irwin@gmail.com> | 2012-06-02 22:48:51 -0700 |
---|---|---|
committer | Conrad Irwin <conrad.irwin@gmail.com> | 2012-06-02 22:48:51 -0700 |
commit | a818f74dc498f4ed5dbb2d314fa7b5e1cdd49759 (patch) | |
tree | 813395572740c001ed2a207040fa6792de38598e | |
parent | 662d8a90d50fa69e2d2ae49e8f96f009875cbc9e (diff) | |
download | method_source-a818f74dc498f4ed5dbb2d314fa7b5e1cdd49759.tar.gz |
Allow source_location to work in eval on 1.8.7
-rw-r--r-- | lib/method_source/source_location.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/method_source/source_location.rb b/lib/method_source/source_location.rb index 9161854..1e2a22a 100644 --- a/lib/method_source/source_location.rb +++ b/lib/method_source/source_location.rb @@ -46,7 +46,7 @@ module MethodSource set_trace_func nil @file = File.expand_path(@file) if @file && File.exist?(File.expand_path(@file)) end - return [@file, @line] if File.exist?(@file.to_s) + [@file, @line] if @file end end end |