You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: 13/umbraco-cms/reference/querying/itagquery.md
+1-6Lines changed: 1 addition & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ If you're using it in Views or Partial views you can inject `ITagQuery` using th
14
14
@inject ITagQuery _tagQuery;
15
15
```
16
16
17
-
After this you can use `_tagQuery` to access the `ITagQuery`.
17
+
After this, you can use `_tagQuery` to access the`ITagQuery`. If your site supports multiple languages, you must specify the desired language when using`ITagQuery`.
18
18
19
19
If you're using it in controllers, you can inject it into the constructor like so:
20
20
@@ -48,11 +48,6 @@ public class TagApiController : UmbracoApiController
48
48
`ITagQuery` is a scoped service, meaning that it should only be injected into scoped or transient services. For more information see the official [Microsoft Documentation](https://docs.microsoft.com/en-us/dotnet/core/extensions/dependency-injection#scoped)
49
49
{% endhint %}
50
50
51
-
52
-
{% hint style="info" %}
53
-
For multi lingual sites, the desired language must be provided when using `ITagQuery`
54
-
{% endhint %}
55
-
56
51
## Examples
57
52
58
53
All examples are from a view using the injection shown above, but working with tags in controllers will be the same.
0 commit comments