November Happy Hour will be moved to Thursday December 5th.

GetLanguageBranches returns no results after recycle

Vote:
 

Hi, I'm upgrading a Episerver 6 site to Episerver 7 (7.0.586.1) and I have some issues with the URL rewrite.

It's working fine for most page types but not for others.
The solution has a custom FriendlyUrlRewriteProvider that calls FriendlyUrlRewriteProvider.ConvertToInternal. I found that DataFactory.GetLanguageBraches (used in UrlSegment.VerifyContentHasSegment) returns zero language branches for the pages that doesn't work and that causes ConvertToInternal to return false.

If I edit the page, GetLanguageBraches will return the expected branches and the rewrite will work. But when the site is restarted the problem is back.

Any ideas what might be causing this?

Thanks!
Martin

#122774
Jun 12, 2015 10:03
Vote:
 

Hi,

Can you paste some code from custom rewrite module? Is rewritting still required when moved to 7.0?

#122805
Jun 15, 2015 13:16
Vote:
 

Hi Valdis, thanks for your reply.

I just found the problem. In a base class to the failing page types the equals-method was overridden in a way that made it return false when it should'nt under some circumstances.
When I changed that code the URL-rewrite started to work :)

Martin

#122811
Edited, Jun 15, 2015 15:58
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.