File tree Expand file tree Collapse file tree 1 file changed +10
-4
lines changed
rxjava-contrib/rxjava-android/src/main/java/rx/operators Expand file tree Collapse file tree 1 file changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -87,18 +87,24 @@ private boolean shouldForwardNotification(Subscriber<? super T> sub) {
87
87
88
88
private void handleLostBinding (Subscriber <? super T > sub , String context ) {
89
89
if (sub == null ) {
90
- Log . d ( LOG_TAG , "subscriber gone; skipping " + context );
90
+ log ( "subscriber gone; skipping " + context );
91
91
} else {
92
92
final R r = boundRef .get ();
93
93
if (r != null ) {
94
94
// the predicate failed to validate
95
- Log . d ( LOG_TAG , "bound component has become invalid; skipping " + context );
95
+ log ( "bound component has become invalid; skipping " + context );
96
96
} else {
97
- Log . d ( LOG_TAG , "bound component gone; skipping " + context );
97
+ log ( "bound component gone; skipping " + context );
98
98
}
99
99
}
100
- Log . d ( LOG_TAG , "unsubscribing..." );
100
+ log ( "unsubscribing..." );
101
101
unsubscribe ();
102
102
}
103
+
104
+ private void log (String message ) {
105
+ if (Log .isLoggable (LOG_TAG , Log .DEBUG )) {
106
+ Log .d (LOG_TAG , message );
107
+ }
108
+ }
103
109
}
104
110
}
You can’t perform that action at this time.
0 commit comments