File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
src/main/java/rx/subscriptions Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change 1
1
/**
2
2
* Copyright 2014 Netflix, Inc.
3
- *
3
+ *
4
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
5
* you may not use this file except in compliance with the License.
6
6
* You may obtain a copy of the License at
7
- *
7
+ *
8
8
* http://www.apache.org/licenses/LICENSE-2.0
9
- *
9
+ *
10
10
* Unless required by applicable law or agreed to in writing, software
11
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -55,8 +55,8 @@ public synchronized boolean isUnsubscribed() {
55
55
* the {@link Subscription} to add
56
56
*/
57
57
public void add (final Subscription s ) {
58
- if (s == null ) {
59
- throw new NullPointerException ( "Added Subscription cannot be null." ) ;
58
+ if (s . isUnsubscribed () ) {
59
+ return ;
60
60
}
61
61
Subscription unsubscribe = null ;
62
62
synchronized (this ) {
You can’t perform that action at this time.
0 commit comments