Description
Steps to reproduce:
- Install https://chrome.google.com/webstore/detail/wordpresscom-for-google-d/baibkfjlahbcogbckhjljjenalhamjbp on Chrome.
- Start a new Google Doc.
- When prompted for permission to run, click the "Continue" button.
- Choose a WordPress.com account.
- Click the "Allow" button to allow WordPress.com for Google Docs permission.
- Add a line of text and an image.
- Go to Add-ons > WordPress.com for Google Docs > Open.
- Click the "Add a WordPress Site" button in the sidebar on the right.
- Make sure you are signed in as the correct user and click the "Approve" button.
- Add a tag and select a category in the sidebar.
- Click the "Save" button in the sidebar on the right.
- Note the very large error message that appears.
- Check the post on the WordPress.com site to see if any content was saved in a draft there.
Result: the category and tag were saved but the line of text and image from the content were not saved and the following error appeared in Google Docs after clicking the Save button:
{"message":"Cannot call method "split" of null.","name":"TypeError","fileName":"Code (WordPress.com for Google Docs)","lineNumber":3388,"stack":"\tat Code (WordPress.com for Google Docs):3388 (hasImageFileExtension)\n\tat Code (WordPress.com for Google Docs):3409 (uploadImage)\n\tat Code (WordPress.com for Google Docs):305 (upload)\n\tat Code (WordPress.com for Google Docs):4095\n\tat Code (WordPress.com for Google Docs):3890 (renderInlineImage)\n\tat Code (WordPress.com for Google Docs):3543 (renderElement)\n\tat Code (WordPress.com for Google Docs):3525 (renderContainer)\n\tat Code (WordPress.com for Google Docs):3656 (renderParagraph)\n\tat Code (WordPress.com for Google Docs):3539 (renderElement)\n\tat Code (WordPress.com for Google Docs):3525 (renderContainer)\n\tat Code (WordPress.com for Google Docs):310 (postToWordPress)\n"}
Seen at https://docs.google.com/document/d/1lIw2253r6VSosUAEClDlh-WjwkkSx38zLQASpdPE0DE/edit using Chrome 58.0.3029.110 on Mac OS X 10.12.5.
Seen at https://wordpress.com/post/design5279.wordpress.com/11119 using Chrome 58.0.3029.110 on Mac OS X 10.12.5 logged in as design5279.
/hat tip @bissy for the original report at https://github.com/Automattic/wp-desktop/issues/304, thank you!