Skip to content

Commit 0b598fa

Browse files
authored
Upgrade (#22)
* Update to 2.3.0 * Bump to 2.0
1 parent 2661144 commit 0b598fa

File tree

5 files changed

+10
-7
lines changed

5 files changed

+10
-7
lines changed

appveyor.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
version: 1.1.{build}
1+
version: 2.0.{build}
22
skip_tags: true
33
skip_branch_with_pr: true
44
test: off

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "graphql-authorization",
3-
"version": "1.1",
3+
"version": "2.0",
44
"main": "index.js",
55
"repository": "[email protected]:graphql-dotnet/authorization.git",
66
"author": "Joe McBride <[email protected]>",

src/GraphQL.Authorization/AuthorizationMetadataExtensions.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,10 @@ public static Task<AuthorizationResult> Authorize(
3030
public static void AuthorizeWith(this IProvideMetadata type, string policy)
3131
{
3232
var list = GetPolicies(type);
33-
list.Fill(policy);
33+
if(!list.Contains(policy))
34+
{
35+
list.Add(policy);
36+
}
3437
type.Metadata[PolicyKey] = list;
3538
}
3639

src/GraphQL.Authorization/GraphQL.Authorization.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
<PropertyGroup>
44
<Description>A toolset for authorizing access to graph types for GraphQL .NET</Description>
5-
<VersionPrefix>1.1</VersionPrefix>
5+
<VersionPrefix>2.0</VersionPrefix>
66
<Authors>Joe McBride</Authors>
77
<TargetFrameworks>netstandard1.3;net46</TargetFrameworks>
88
<AssemblyName>GraphQL.Authorization</AssemblyName>
@@ -24,7 +24,7 @@
2424
</ItemGroup>
2525

2626
<ItemGroup>
27-
<PackageReference Include="GraphQL" Version="2.0.0" />
27+
<PackageReference Include="GraphQL" Version="2.3.0" />
2828
</ItemGroup>
2929

3030
<ItemGroup Condition="'$(TargetFramework)' == 'netstandard1.3'">

src/Harness/Harness.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@
1313
</ItemGroup>
1414

1515
<ItemGroup>
16-
<PackageReference Include="GraphQL" Version="2.0.0" />
16+
<PackageReference Include="GraphQL" Version="2.3.0" />
1717
<PackageReference Include="GraphQL.Server.Ui.GraphiQL" Version="3.1.0" />
1818
<PackageReference Include="GraphQL.Server.Transports.AspNetCore" Version="3.1.0" />
19-
<PackageReference Include="Microsoft.AspNetCore.All" Version="2.0.5" />
19+
<PackageReference Include="Microsoft.AspNetCore.All" Version="2.0.9" />
2020
</ItemGroup>
2121

2222
<ItemGroup>

0 commit comments

Comments
 (0)