Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes shareViaSMS bug, opts.image present removes message body #1148

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

srhyne
Copy link

@srhyne srhyne commented Jul 16, 2021

Issue...

If options.image passed, options.message was not present in iOS message controller.

  • replaces getFile call with getImage call
  • translates image to png and then attaches as addAttachmentData instead of addAttachmentURL

Modified:

  • src/ios/SocialSharing.m

You can recreate the issue with the following code. "test" will not be added to the body of the SMS but the image will be present.

function testSharing(){
    var options = {
      message : 'test',
      image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg=='
    }
  
    plugins.socialsharing.shareViaSMS(options)
}

Issue...

If options.image passed, options.message was not present

- replaces getFile call with getImage call
- translates image to png and then attaches as data vs URL

Modified:

- src/ios/SocialSharing.m
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant