[ 
https://issues.apache.org/jira/browse/CB-10696?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15890794#comment-15890794
 ] 

ASF GitHub Bot commented on CB-10696:
-------------------------------------

Github user blankg commented on a diff in the pull request:

    
https://github.com/apache/cordova-plugin-file-transfer/pull/175#discussion_r103760457
  
    --- Diff: src/ios/CDVFileTransfer.m ---
    @@ -440,13 +440,23 @@ - (void)download:(CDVInvokedUrlCommand*)command
             targetURL = [[self.commandDelegate getCommandInstance:@"File"] 
fileSystemURLforLocalPath:target].url;
         } else {
             targetURL = [NSURL URLWithString:target];
    +
    +        if (targetURL == nil) {
    +            NSString* targetUrlTextEscaped = [target 
stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding];
    --- End diff --
    
    stringByAddingPercentEscapesUsingEncoding is deprecated, would be better to 
use [target stringByAddingPercentEncodingWithAllowedCharacters:[NSCharacterSet 
URLFragmentAllowedCharacterSet]]


> Error while downloading file who are having spaces between name in ios using 
> cordova
> ------------------------------------------------------------------------------------
>
>                 Key: CB-10696
>                 URL: https://issues.apache.org/jira/browse/CB-10696
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: Plugin File Transfer
>            Reporter: Akashdeep Sharma
>            Assignee: Nikita Matrosov
>            Priority: Minor
>              Labels: cannot-reproduce, ios, triaged, wfc
>
> I have used the filetransfer code of your for file download and would like 
> thank you for that tutorial. It work well on android but when i try to 
> download a file that have space between it throws error in ios for example 
> file name "Test Doc.pdf" its get downloaded in android but in ios throws 
> error. Can you please guide what to do??



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to