sub construct_tokens { my ($self, $oauth2, $response) = @_; my $content = eval {decode_json($response->content)}; unless ($@) { $content->{'token_type'} = 'bearer'; $response->content(encode_json($content)); } $self->SUPER::construct_tokens($oauth2, $response); }