mirror of
				https://github.com/commons-app/apps-android-commons.git
				synced 2025-10-30 22:34:02 +01:00 
			
		
		
		
	refactor: permission should not be check on onCreate for some cases
This commit is contained in:
		
							parent
							
								
									1995c0a86c
								
							
						
					
					
						commit
						349b8ef482
					
				
					 1 changed files with 11 additions and 8 deletions
				
			
		|  | @ -162,14 +162,17 @@ public class MainActivity  extends BaseActivity | |||
|              * so that location in the EXIF metadata of the images shared by the user | ||||
|              * is retained on devices running Android 10 or above | ||||
|              */ | ||||
|             if (VERSION.SDK_INT >= VERSION_CODES.Q) { | ||||
|                 PermissionUtils.checkPermissionsAndPerformAction( | ||||
|                     this, | ||||
|                     () -> {}, | ||||
|                     R.string.media_location_permission_denied, | ||||
|                     R.string.add_location_manually, | ||||
|                     permission.ACCESS_MEDIA_LOCATION); | ||||
|             } | ||||
| //            if (VERSION.SDK_INT >= VERSION_CODES.Q) { | ||||
| //                ActivityCompat.requestPermissions(this, | ||||
| //                    new String[]{Manifest.permission.ACCESS_MEDIA_LOCATION}, 0); | ||||
| //                PermissionUtils.checkPermissionsAndPerformAction( | ||||
| //                    this, | ||||
| //                    () -> {}, | ||||
| //                    R.string.media_location_permission_denied, | ||||
| //                    R.string.add_location_manually, | ||||
| //                    permission.ACCESS_MEDIA_LOCATION); | ||||
| //            } | ||||
| 
 | ||||
|             checkAndResumeStuckUploads(); | ||||
|         } | ||||
|     } | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Rohit Verma
						Rohit Verma