[SOLVED] Assets - Wrong returned URL for assets

I have…

  • [ ] Checked the logs and have uploaded a log file and provided a link because I found something suspicious there. Please do not post the log file in the topic because very often something important is missing.

I’m submitting a…

  • [ ] Regression (a behavior that stopped working in a new release)
  • [ x ] Bug report
  • [ ] Performance issue
  • [ ] Documentation issue or request

Current behavior

GraphQL queries are providing invalid URLs for assets (missing “/api/”).
This behavior did not happen in version 4.6.0

Expected behavior

Minimal reproduction of the problem

Upgrade from version 4.6.0 to 5.0.0 and create a simple query with GraphQL thats returns a asset url

Environment

  • [ x ] Self hosted with docker
  • [ ] Self hosted with IIS
  • [ ] Self hosted with other version
  • [ ] Cloud version

Version: 5.0.0

Browser:

  • [ ] Chrome (desktop)
  • [ ] Chrome (Android)
  • [ ] Chrome (iOS)
  • [ ] Firefox
  • [ ] Safari (desktop)
  • [ ] Safari (iOS)
  • [ ] IE
  • [ ] Edge

Others:
I think the wrong code part is in “squidex/backend/src/Squidex.Web/Services/UrlGenerator.cs”, at line 55:

public string AssetContent(NamedId appId, string idOrSlug)
{
return urlsOptions.BuildUrl($“assets/{appId.Name}/{idOrSlug}”);
}

1 Like

It seems it was fixed in the git version.

Yes, it was. Sorry for not updating it here.