From 7e0c7e47f5e4dccff104d2e4ca87e0d2255a4d2a Mon Sep 17 00:00:00 2001 From: Hakan Nilsson Date: Mon, 6 Nov 2017 22:06:11 +0100 Subject: [PATCH] Response record fields can be undefined --- src/oauth2_response.erl | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/oauth2_response.erl b/src/oauth2_response.erl index c6fd96e..f0161cb 100644 --- a/src/oauth2_response.erl +++ b/src/oauth2_response.erl @@ -54,13 +54,13 @@ %%%_ * Types ----------------------------------------------------------- -record(response, { - access_token :: oauth2:token() - ,access_code :: oauth2:token() - ,expires_in :: oauth2:lifetime() - ,resource_owner :: term() - ,scope :: oauth2:scope() - ,refresh_token :: oauth2:token() - ,refresh_token_expires_in :: oauth2:lifetime() + access_token :: undefined | oauth2:token() + ,access_code :: undefined | oauth2:token() + ,expires_in :: undefined | oauth2:lifetime() + ,resource_owner :: undefined | term() + ,scope :: undefined | oauth2:scope() + ,refresh_token :: undefined | oauth2:token() + ,refresh_token_expires_in :: undefined | oauth2:lifetime() ,token_type = ?TOKEN_TYPE :: binary() }).