mirror of
				https://github.com/owncloud/android-library.git
				synced 2025-10-31 02:17:41 +00:00 
			
		
		
		
	Update ErrorMessageAdapter class to generate appropiate error messages for operations failed due to lack of permissions (ResultCode.FORBIDDEN)
This commit is contained in:
		
							parent
							
								
									0862c66b7d
								
							
						
					
					
						commit
						7636d9e037
					
				| @ -99,7 +99,8 @@ public class RemoteOperationResult implements Serializable { | |||||||
|         INVALID_CHARACTER_IN_NAME, |         INVALID_CHARACTER_IN_NAME, | ||||||
|         SHARE_NOT_FOUND, |         SHARE_NOT_FOUND, | ||||||
| 		LOCAL_STORAGE_NOT_REMOVED, | 		LOCAL_STORAGE_NOT_REMOVED, | ||||||
| 		FORBIDDEN | 		FORBIDDEN, | ||||||
|  | 		SHARE_FORBIDDEN | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     private boolean mSuccess = false; |     private boolean mSuccess = false; | ||||||
|  | |||||||
| @ -142,6 +142,9 @@ public class CreateRemoteShareOperation extends RemoteOperation { | |||||||
| 				} else if (xmlParser.isFileNotFound()){ | 				} else if (xmlParser.isFileNotFound()){ | ||||||
| 					result = new RemoteOperationResult(ResultCode.SHARE_NOT_FOUND); | 					result = new RemoteOperationResult(ResultCode.SHARE_NOT_FOUND); | ||||||
| 					 | 					 | ||||||
|  | 				} else if (xmlParser.isFailure()) { | ||||||
|  | 					result = new RemoteOperationResult(ResultCode.SHARE_FORBIDDEN); | ||||||
|  | 
 | ||||||
| 				} else { | 				} else { | ||||||
| 					result = new RemoteOperationResult(false, status, post.getResponseHeaders());	 | 					result = new RemoteOperationResult(false, status, post.getResponseHeaders());	 | ||||||
| 				} | 				} | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user