hometown 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/hometown/creation_tracer.rb +6 -1
- data/lib/hometown/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6faccd91b19c91bb38e978cae748c863bb1997c0
|
4
|
+
data.tar.gz: c7d57e8b40777dbadfa4c6e7171c0a7ff240e74b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7cde03cef004ca7e1121d7cc6e15cfdb51753fe663f66e63239ab45ac0315866d3b293bf70565f647102faaf608a48394efc163cdb68906bec87cdee56fa654d
|
7
|
+
data.tar.gz: df5d5a65aaa19c4efd14f6a9da712ad699c477d223551ffc901247ffa634587a5c752a53980776dd87ebdd89d74138429fb2767202524d21f0c8c061927601ce
|
@@ -46,10 +46,15 @@ module Hometown
|
|
46
46
|
HOMETOWN_TRACE_ON_INSTANCE = :@__hometown_creation_backtrace
|
47
47
|
|
48
48
|
def add_trace_for(instance)
|
49
|
-
trace = Hometown::Trace.new(instance.class,
|
49
|
+
trace = Hometown::Trace.new(instance.class, scrubbed_caller)
|
50
50
|
instance.instance_variable_set(HOMETOWN_TRACE_ON_INSTANCE, trace)
|
51
51
|
end
|
52
52
|
|
53
|
+
def scrubbed_caller
|
54
|
+
backtrace = caller.dup
|
55
|
+
backtrace.reject { |line| %r{/lib/hometown/creation_tracer.rb}.match(line) }
|
56
|
+
end
|
57
|
+
|
53
58
|
def find_trace_for(instance)
|
54
59
|
instance.instance_variable_get(HOMETOWN_TRACE_ON_INSTANCE)
|
55
60
|
end
|
data/lib/hometown/version.rb
CHANGED