WIP Implement a generic handler for OAuth.

This commit is contained in:
Laurent Destailleur
2022-08-04 15:58:00 +02:00
parent 1093084e9b
commit 4a9c9a97e5
9 changed files with 320 additions and 51 deletions

View File

@@ -1,5 +1,5 @@
<?php
/*
/* Copyright (C) 2022 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2015 Frederic France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
@@ -86,7 +86,7 @@ if ($action != 'delete' && empty($requestedpermissionsarray)) {
//var_dump($requestedpermissionsarray);exit;
// Instantiate the Api service using the credentials, http client and storage mechanism for the token
$apiService = $serviceFactory->createService('GitHub'.($keyforprovider ? '-'.$keyforprovider : ''), $credentials, $storage, $requestedpermissionsarray);
$apiService = $serviceFactory->createService('GitHub', $credentials, $storage, $requestedpermissionsarray);
// access type needed to have oauth provider refreshing token
//$apiService->setAccessType('offline');