Skip to content

Commit

Permalink
use request callbacks
Browse files Browse the repository at this point in the history
  • Loading branch information
aspriddell committed Aug 12, 2022
1 parent a6c1209 commit 07b2775
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions DragonFruit.Link/SteamApiRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
using System;
using DragonFruit.Data;
using DragonFruit.Data.Parameters;
using DragonFruit.Data.Requests;
using DragonFruit.Link.Exceptions;
using Newtonsoft.Json;

Expand All @@ -12,7 +13,7 @@
namespace DragonFruit.Link
{
[JsonObject(MemberSerialization.OptIn)]
public abstract class SteamApiRequest : ApiRequest
public abstract class SteamApiRequest : ApiRequest, IRequestExecutingCallback
{
protected override Methods Method => Methods.Get;
protected override bool RequireAuth => false; // this only checks headers, ours is in the query
Expand All @@ -33,7 +34,7 @@ public abstract class SteamApiRequest : ApiRequest
[QueryParameter("format")]
protected string OutputFormat => "json";

protected override void OnRequestExecuting(ApiClient client)
public void OnRequestExecuting(ApiClient client)
{
if (RequireApiKey && string.IsNullOrEmpty(ApiKey))
{
Expand Down

0 comments on commit 07b2775

Please sign in to comment.