umbraco / Umbraco-CMS

Umbraco is a free and open source .NET content management system helping you deliver delightful digital experiences.
https://umbraco.com
Other
4.49k stars 2.69k forks source link

V8.5.1: Ambiguous extension method signature between embedded and external ModelsBuilder #7469

Closed sniffdk closed 4 years ago

sniffdk commented 4 years ago

The IPublishedContent .Value extension method that takes an Expression<Func<TModel, TValue>> parameter is duplicated in the new embedded ModelsBuilder. Due to them being in the same namespace, there is an ambiguous call between the two, as the method signatures are identical. Screenshots below: image

image

nul800sebastiaan commented 4 years ago

Thanks again Mads, we're looking into it!

ronaldbarendse commented 4 years ago

This issue is now fixed in PR #7470 by renaming the Umbraco.ModelsBuilder.Embedded version of Value(...) to ValueFor(...):

https://github.com/umbraco/Umbraco-CMS/blob/41dc8d915bdcadb628e6dde9422586310ac66a1b/src/Umbraco.ModelsBuilder.Embedded/PublishedElementExtensions.cs#L20

clausjensen commented 4 years ago

Closing this one - fixed (final fix) in 8.5.3 😄

bielu commented 4 years ago

@nul800sebastiaan This one should be flagged as braking change name of Extension method was changed, which means we break code which was using that.

nul800sebastiaan commented 4 years ago

Okay, done.