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

Craft 5 support? #29

Closed
antcooper opened this issue Jun 14, 2024 · 10 comments
Closed

Craft 5 support? #29

antcooper opened this issue Jun 14, 2024 · 10 comments

Comments

@antcooper
Copy link

We're just planning some site upgrades and I wonder if you're planning to support Craft 5? Thanks

@bymayo
Copy link
Contributor

bymayo commented Aug 8, 2024

Any update on this?

@bymayo
Copy link
Contributor

bymayo commented Sep 24, 2024

@antcooper I've just added a pull request for this, and updated it for Craft 5 (#30)

You can use this in your repo if you wish until Venveo accept the pull request by adding it to your composer file:

  "require": {
    "venveo/craft-compress": "dev-craft-5",
  }

And

  "repositories": [
    {
      "type": "vcs",
      "url": "https://github.com/madebyshape/craft-compress.git"
    }
  ]

@Mosnar
Copy link
Contributor

Mosnar commented Sep 24, 2024

Oh awesome, thanks @bymayo!

@bymayo
Copy link
Contributor

bymayo commented Sep 24, 2024

@Mosnar No problem, hopefully you merge it! :)

@Mosnar
Copy link
Contributor

Mosnar commented Sep 24, 2024

It's merged but I was doing some testing before tagging a release and I'm seeing some issues with the download links not working, so I'm digging into that.

@Mosnar
Copy link
Contributor

Mosnar commented Sep 24, 2024

I'm a dummy and forgot to set the default volume. Tagged 5.0.0!

@Mosnar Mosnar closed this as completed Sep 24, 2024
@kennethormandy
Copy link

Thanks for this! Out of curiosity, what was the reason behind this change? e3818ad

To my knowledge, getContents() is still present and unchanged in Craft 5.

It looks like that might also impact filesystems without public URLs? Maybe not though.

@bymayo
Copy link
Contributor

bymayo commented Sep 25, 2024

@kennethormandy I changed this because i kept getting an error for the getContents() function:

2024-09-24 16:37:24 [web.ERROR] [Error] Error: Call to a member function getAsset() on null in /var/www/html/vendor/venveo/craft-compress/src/controllers/CompressController.php:73

I wasn't sure if this was because we were using Servd and their remote storage and it was struggling to grab the image.

I suppose if you want to keep the way i've done it, you could just pass the path rather than the url if some filesystems don't have public URL's

@Mosnar
Copy link
Contributor

Mosnar commented Sep 25, 2024

Let me look into this a little closer.

@Mosnar
Copy link
Contributor

Mosnar commented Sep 25, 2024

Opened #31

@Mosnar Mosnar closed this as completed Sep 25, 2024
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

No branches or pull requests

4 participants