File tree Expand file tree Collapse file tree
extractor/src/main/java/org/schabi/newpipe/extractor/stream Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -68,7 +68,7 @@ public Stream(final String id,
6868 * @param streamList the list of {@link Stream}s which will be compared
6969 * @return whether the list already contains one stream with equals stats
7070 */
71- public static boolean containSimilarStream (final Stream stream ,
71+ public static boolean containSimilarStream (@ Nonnull final Stream stream ,
7272 final List <? extends Stream > streamList ) {
7373 if (isNullOrEmpty (streamList )) {
7474 return false ;
@@ -98,11 +98,9 @@ public static boolean containSimilarStream(final Stream stream,
9898 * @return whether the stream have the same stats or not, based on the criteria above
9999 */
100100 public boolean equalStats (@ Nullable final Stream other ) {
101- if (other == null || mediaFormat == null || other .mediaFormat == null ) {
102- return false ;
103- }
104- return mediaFormat .id == other .mediaFormat .id && deliveryMethod == other .deliveryMethod
105- && isUrl == other .isUrl ;
101+ return other != null && mediaFormat != null && other .mediaFormat != null
102+ && mediaFormat .id == other .mediaFormat .id && deliveryMethod == other .deliveryMethod
103+ && isUrl == other .isUrl ;
106104 }
107105
108106 /**
@@ -137,6 +135,7 @@ public String getUrl() {
137135 *
138136 * @return the content or URL
139137 */
138+ @ Nonnull
140139 public String getContent () {
141140 return content ;
142141 }
You can’t perform that action at this time.
0 commit comments