Error occurred pasting images after update to 0.25.2 #1093

Closed
opened 2026-02-04 23:44:17 +03:00 by OVERLORD · 6 comments
Owner

Originally created by @BrentOates on GitHub (Mar 18, 2019).

Describe the bug
After updating to the latest version of BookStack (v0.25.2), attempting to paste an image into a page will produce the error "An error occurred uploading this image".

If I check the directory where the images are stored, the image has uploaded, and I am able to view the image so it hasn't corrupted, but the thumbnail is not showing and it cannot be inserted manually either from within the BookStack.

Steps To Reproduce
Steps to reproduce the behavior:

  1. Create / Edit a page within BookStack
  2. Paste an image copied from Google Images, snipping tool etc.
  3. Receive error

Expected behavior
As with the previous version, the image should paste into the document.

Screenshots
image

Your Configuration (please complete the following information):

  • Exact BookStack Version (Found in settings): v0.25.2
  • PHP Version: 7.2
  • Hosting Method (Nginx/Apache/Docker): Apache

Additional context
I saw in the changelog something related to images, so unsure if it is to do with that, also the uploads folder where images are stored no longer have a thumbnails folder in there as with folders from previous dates.
Apache has appropriate access to these folders.

Originally created by @BrentOates on GitHub (Mar 18, 2019). **Describe the bug** After updating to the latest version of BookStack (v0.25.2), attempting to paste an image into a page will produce the error "An error occurred uploading this image". If I check the directory where the images are stored, the image has uploaded, and I am able to view the image so it hasn't corrupted, but the thumbnail is not showing and it cannot be inserted manually either from within the BookStack. **Steps To Reproduce** Steps to reproduce the behavior: 1. Create / Edit a page within BookStack 2. Paste an image copied from Google Images, snipping tool etc. 3. Receive error **Expected behavior** As with the previous version, the image should paste into the document. **Screenshots** ![image](https://user-images.githubusercontent.com/3065898/54553364-eca44500-49a9-11e9-94c8-9b22e1a07aa2.png) **Your Configuration (please complete the following information):** - Exact BookStack Version (Found in settings): v0.25.2 - PHP Version: 7.2 - Hosting Method (Nginx/Apache/Docker): Apache **Additional context** I saw in the changelog something related to images, so unsure if it is to do with that, also the uploads folder where images are stored no longer have a thumbnails folder in there as with folders from previous dates. Apache has appropriate access to these folders.
OVERLORD added the 🐕 Support label 2026-02-04 23:44:17 +03:00
Author
Owner

@BrentOates commented on GitHub (Mar 18, 2019):

Also worth noting, there aren't errors coming up in the laravel.log file or with the app in debug mode.

@BrentOates commented on GitHub (Mar 18, 2019): Also worth noting, there aren't errors coming up in the laravel.log file or with the app in debug mode.
Author
Owner

@ssddanbrown commented on GitHub (Mar 20, 2019):

Hi @BrentOates, Sorry to hear you're experiencing issues.

Do you know what version of BookStack you updated from?
Also, What image storage option do you use? Default file storage, secure storage or s3/remote storage?

Were any .env options changed upon upgrade?

@ssddanbrown commented on GitHub (Mar 20, 2019): Hi @BrentOates, Sorry to hear you're experiencing issues. Do you know what version of BookStack you updated from? Also, What image storage option do you use? Default file storage, secure storage or s3/remote storage? Were any `.env` options changed upon upgrade?
Author
Owner

@BrentOates commented on GitHub (Mar 21, 2019):

Hey,

I updated from v0.25.1 as I've tried keeping up to date where possible so was on the latest version prior to that.

It's using the default storage options at the moment and there's not been any changes to the .env file

@BrentOates commented on GitHub (Mar 21, 2019): Hey, I updated from v0.25.1 as I've tried keeping up to date where possible so was on the latest version prior to that. It's using the default storage options at the moment and there's not been any changes to the `.env` file
Author
Owner

@BrentOates commented on GitHub (Apr 2, 2019):

Noticed today after trying again with the latest updated, some error coming out in the console:

TypeError: Cannot read property "indexOf" of null
    at Aw.convertURL (tinymce.min.js?ver=4.6.6:2)
    at Object.set (tinymce.min.js?ver=4.6.6:2)
    at Object.y [as setAttrib] (tinymce.min.js?ver=4.6.6:2)
    at app.js?version=v0.25.5:67
@BrentOates commented on GitHub (Apr 2, 2019): Noticed today after trying again with the latest updated, some error coming out in the console: ``` TypeError: Cannot read property "indexOf" of null at Aw.convertURL (tinymce.min.js?ver=4.6.6:2) at Object.set (tinymce.min.js?ver=4.6.6:2) at Object.y [as setAttrib] (tinymce.min.js?ver=4.6.6:2) at app.js?version=v0.25.5:67 ```
Author
Owner

@cunba-ai commented on GitHub (Jul 5, 2019):

image
data after jsonstringfy is {} when a image pasted

And server reports 500 http code:
production.ERROR: Type error: Argument 1 passed to BookStack\Uploads\ImageRepo::saveNew() must be an instance of Symfony\Component\HttpFoundation\File\UploadedFile, null given, called

@cunba-ai commented on GitHub (Jul 5, 2019): ![image](https://user-images.githubusercontent.com/121495/60699330-f2f10980-9f25-11e9-8d60-63b97ed8aec2.png) data after jsonstringfy is {} when a image pasted And server reports 500 http code: production.ERROR: Type error: Argument 1 passed to BookStack\Uploads\ImageRepo::saveNew() must be an instance of Symfony\Component\HttpFoundation\File\UploadedFile, null given, called
Author
Owner

@ssddanbrown commented on GitHub (Dec 17, 2020):

Since the last comment on this issue is relatively old I'm going to close this. If the issue remains and is something you still require to be fixed please open a new issue, referencing this one.

@ssddanbrown commented on GitHub (Dec 17, 2020): Since the last comment on this issue is relatively old I'm going to close this. If the issue remains and is something you still require to be fixed please open a new issue, referencing this one.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#1093