Jump to content

RockIcons Backend Error after Upgrade of RockFrontend and Less modules


Recommended Posts

Posted

Hi @bernhard,

after we upgraded RockFrontend and Less to latest versions in a project, we got this error in the backend:

image.thumb.png.e74cd363da89ca4a5513c5832ca77cf9.png

This is caused by the call to $this->createAssets() call in RockIcons.module.php init() method.

Further tracing it back, we found that the L1101 in RockFrontend.module.php is the cause.
Changing $lessFile = $this->getFile($lessFile); to $lessFile = $this->getFile($lessFile, true); fixes it.

The getFile method has default false for $forcePath and returns an empty string when $forcePath is set to false  which causes L1102 to throw a WireException. and ultimately leads to the error message from wire/core/ModulesLoader.php around L167. When passing $forcePath = true, the correct file path is returned. We checked and in our setup the createAssets method in RockIcons.module.php is the only caller of the lessToCss method in RockFrontend.

This might be related to your refactor of RockFrontend/RockDevTools.

While it is only happening when logged in as superuser, it still is troublesome because the error in the backend never goes away and icons don't display in the frontend. Frontend is still  functional when not logged in as superuser. 

 

  • gebeer changed the title to RockIcons Backend Error after Upgrade of RockFrontend and Less modules
Posted
24 minutes ago, bernhard said:

Hey @gebeer thx for that report! I have pushed your suggested fix on the dev branch of RockFrontend 🙂 

Wow, that was quick. Thanks. Will wait until it goes into main and then update through module interface.

  • Like 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...