The current hook_requirements() implementation is calling the url function at multiple places (The function doesn't exist anymore and has been removed).
The .module file also contains calls to url, they have to be replaced.

Comments

jsacksick’s picture

Issue summary: View changes
jsacksick’s picture

Status: Active » Needs review
StatusFileSize
new4.96 KB

I'm not sure whether to use Url::fromRoute('composer_manager.packages_page')->toString()or \Drupal::url('composer_manager.packages_page')
The attached patch seems to work fine.

cpliakas’s picture

Status: Needs review » Reviewed & tested by the community

Looks good to me. Thanks for helping to keep us up to date with D8 head!

jsacksick’s picture

Issue summary: View changes
JulienD’s picture

The patch worked for me too

JulienD’s picture

Status: Reviewed & tested by the community » Needs review
StatusFileSize
new6.99 KB

l() and url() have been replaced by an improved URL generation API today - #2346779- and the module generates a WSOD.

Here is the updated patch that fixes the use to the l() function

JulienD’s picture

Rerolled the patch to remove calls to \Drupal::url('') as Jonathan mentioned previously

bojanz’s picture

Status: Needs review » Needs work

@Julien

I just posted a duplicate in #2348237: Remove deprecated calls to l() :(
Please use the LinkGenerator trait like I did in https://www.drupal.org/files/issues/2348237-1-remove-deprecated-l-calls....

The $link in the AutoloaderSubscriber should either be removed, or the LinkGenerator injected via the constructor.

JulienD’s picture

Here is a new version of the patch that include Bojan's feedback.

Thx!

JulienD’s picture

Status: Needs work » Needs review
lachezar.valchev’s picture

Just tried it out against beta1. Works for me as well.

Thanks!

cpliakas’s picture

Status: Needs review » Reviewed & tested by the community

bojanz, thanks for guiding us to best practices.

All, thanks for re-rolling and testing.

jbrown’s picture

Please commit this! ;-)

guguss’s picture

#9 Fixed the issue for me too. Ready to be merged.

pcambra’s picture

Just confirming the RTBC :)

ByronNorris’s picture

#9 worked for me as well! Thanks. RTBC++

cpliakas’s picture

Sounds good, just got back from a trip to Spain so I was offline.

@jbrown, do you want commit access to expedite D8 fixes getting pushed to the codebase?

martin107’s picture

Title: Remove deprecated calls to url » Remove deprecated calls to url() and l()

more than just url has been fixed :)

jbrown’s picture

@cpliakas yes please give me commit access so I can push these API changes.

bojanz’s picture

Status: Reviewed & tested by the community » Fixed

Committed :)

  • bojanz committed 43cde66 on 8.x-1.x authored by JulienD
    Issue #2347559 by JulienD, jsacksick: Remove deprecated calls to url()...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.