mirror of
				https://github.com/TeamNewPipe/NewPipe
				synced 2025-10-31 07:13:00 +00:00 
			
		
		
		
	Fixing squid:UselessParenthesesCheck - Useless parentheses around expressions should be removed to prevent any misunderstanding.
This commit is contained in:
		| @@ -564,9 +564,9 @@ public class YoutubeStreamExtractor extends StreamExtractor { | |||||||
|                     } |                     } | ||||||
|                 } |                 } | ||||||
|  |  | ||||||
|                 int seconds = (secondsString.isEmpty() ? 0 : Integer.parseInt(secondsString)); |                 int seconds = secondsString.isEmpty() ? 0 : Integer.parseInt(secondsString); | ||||||
|                 int minutes = (minutesString.isEmpty() ? 0 : Integer.parseInt(minutesString)); |                 int minutes = minutesString.isEmpty() ? 0 : Integer.parseInt(minutesString); | ||||||
|                 int hours = (hoursString.isEmpty() ? 0 : Integer.parseInt(hoursString)); |                 int hours = hoursString.isEmpty() ? 0 : Integer.parseInt(hoursString); | ||||||
|  |  | ||||||
|                 //don't trust BODMAS! |                 //don't trust BODMAS! | ||||||
|                 int ret = seconds + (60 * minutes) + (3600 * hours); |                 int ret = seconds + (60 * minutes) + (3600 * hours); | ||||||
| @@ -794,7 +794,7 @@ public class YoutubeStreamExtractor extends StreamExtractor { | |||||||
|         } finally { |         } finally { | ||||||
|             Context.exit(); |             Context.exit(); | ||||||
|         } |         } | ||||||
|         return (result == null ? "" : result.toString()); |         return result == null ? "" : result.toString(); | ||||||
|     } |     } | ||||||
|  |  | ||||||
|     private String findErrorReason(Document doc) { |     private String findErrorReason(Document doc) { | ||||||
|   | |||||||
| @@ -157,7 +157,7 @@ public class BackgroundPlayer extends Service /*implements MediaPlayer.OnPrepare | |||||||
|                 e.printStackTrace(); |                 e.printStackTrace(); | ||||||
|             } |             } | ||||||
|  |  | ||||||
|             WifiManager wifiMgr = ((WifiManager)getSystemService(Context.WIFI_SERVICE)); |             WifiManager wifiMgr = (WifiManager)getSystemService(Context.WIFI_SERVICE); | ||||||
|             wifiLock = wifiMgr.createWifiLock(WifiManager.WIFI_MODE_FULL, TAG); |             wifiLock = wifiMgr.createWifiLock(WifiManager.WIFI_MODE_FULL, TAG); | ||||||
|  |  | ||||||
|             //listen for end of video |             //listen for end of video | ||||||
|   | |||||||
| @@ -327,7 +327,7 @@ public class PlayVideoActivity extends AppCompatActivity { | |||||||
|  |  | ||||||
|             int realHeight = realDisplayMetrics.heightPixels; |             int realHeight = realDisplayMetrics.heightPixels; | ||||||
|             int displayHeight = displayMetrics.heightPixels; |             int displayHeight = displayMetrics.heightPixels; | ||||||
|             return (realHeight - displayHeight); |             return realHeight - displayHeight; | ||||||
|         } else { |         } else { | ||||||
|             return 50; |             return 50; | ||||||
|         } |         } | ||||||
| @@ -344,7 +344,7 @@ public class PlayVideoActivity extends AppCompatActivity { | |||||||
|  |  | ||||||
|             int realWidth = realDisplayMetrics.widthPixels; |             int realWidth = realDisplayMetrics.widthPixels; | ||||||
|             int displayWidth = displayMetrics.widthPixels; |             int displayWidth = displayMetrics.widthPixels; | ||||||
|             return (realWidth - displayWidth); |             return realWidth - displayWidth; | ||||||
|         } else { |         } else { | ||||||
|             return 50; |             return 50; | ||||||
|         } |         } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Faisal Hameed
					Faisal Hameed