готовность к дублированию проекта
This commit is contained in:
parent
050c42c282
commit
a6038acda7
|
@ -1,4 +1,4 @@
|
||||||
# Marina
|
# Marina
|
||||||
### Discord chat-robot
|
### Discord chat-robot
|
||||||
|
|
||||||
For our server BEBRA DREAMERS
|
For our server **BEBRA DREAMERS**
|
||||||
|
|
|
@ -33,7 +33,7 @@
|
||||||
"php": "~8.2",
|
"php": "~8.2",
|
||||||
"mirzaev/minimal": "^2.2",
|
"mirzaev/minimal": "^2.2",
|
||||||
"mirzaev/arangodb": "^1.3.0",
|
"mirzaev/arangodb": "^1.3.0",
|
||||||
"triagens/arangodb": "~3.9.x-dev",
|
"triagens/arangodb": "~3.10.x-dev",
|
||||||
"guzzlehttp/guzzle": "^7.5",
|
"guzzlehttp/guzzle": "^7.5",
|
||||||
"wohali/oauth2-discord-new": "^1.2"
|
"wohali/oauth2-discord-new": "^1.2"
|
||||||
},
|
},
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||||
"This file is @generated automatically"
|
"This file is @generated automatically"
|
||||||
],
|
],
|
||||||
"content-hash": "b0b28e01189100f963205a827c33bc7c",
|
"content-hash": "35a83d010513f763290f92c01c2102aa",
|
||||||
"packages": [
|
"packages": [
|
||||||
{
|
{
|
||||||
"name": "guzzlehttp/guzzle",
|
"name": "guzzlehttp/guzzle",
|
||||||
|
@ -817,16 +817,16 @@
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "triagens/arangodb",
|
"name": "triagens/arangodb",
|
||||||
"version": "3.9.x-dev",
|
"version": "3.10.x-dev",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/arangodb/arangodb-php.git",
|
"url": "https://github.com/arangodb/arangodb-php.git",
|
||||||
"reference": "21c460dbbd75eb5c066f9abcc3a9adf4487d6e48"
|
"reference": "a378f9595b54ff16c9533b264e8d0709a2432da0"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/arangodb/arangodb-php/zipball/21c460dbbd75eb5c066f9abcc3a9adf4487d6e48",
|
"url": "https://api.github.com/repos/arangodb/arangodb-php/zipball/a378f9595b54ff16c9533b264e8d0709a2432da0",
|
||||||
"reference": "21c460dbbd75eb5c066f9abcc3a9adf4487d6e48",
|
"reference": "a378f9595b54ff16c9533b264e8d0709a2432da0",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
|
@ -872,9 +872,9 @@
|
||||||
],
|
],
|
||||||
"support": {
|
"support": {
|
||||||
"issues": "https://github.com/arangodb/arangodb-php/issues",
|
"issues": "https://github.com/arangodb/arangodb-php/issues",
|
||||||
"source": "https://github.com/arangodb/arangodb-php/tree/3.9"
|
"source": "https://github.com/arangodb/arangodb-php/tree/3.10"
|
||||||
},
|
},
|
||||||
"time": "2022-10-21T15:30:53+00:00"
|
"time": "2022-10-21T15:30:45+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "wohali/oauth2-discord-new",
|
"name": "wohali/oauth2-discord-new",
|
||||||
|
|
|
@ -29,7 +29,7 @@ final class index extends core
|
||||||
|
|
||||||
// Step 1. Get authorization code
|
// Step 1. Get authorization code
|
||||||
$_SESSION['oauth2state'] = $this->provider->getState();
|
$_SESSION['oauth2state'] = $this->provider->getState();
|
||||||
header('Location: ' . $this->provider->getAuthorizationUrl());
|
header('Location: ' . $this->provider->getAuthorizationUrl(require '../settings/discord/settings.php'));
|
||||||
|
|
||||||
// Check given state against previously stored one to mitigate CSRF attack
|
// Check given state against previously stored one to mitigate CSRF attack
|
||||||
} elseif (empty($parameters['state']) || ($parameters['state'] !== $_SESSION['oauth2state'])) {
|
} elseif (empty($parameters['state']) || ($parameters['state'] !== $_SESSION['oauth2state'])) {
|
||||||
|
|
|
@ -57,7 +57,7 @@ class core extends model
|
||||||
{
|
{
|
||||||
parent::__construct($initialize);
|
parent::__construct($initialize);
|
||||||
|
|
||||||
/* if ($initialize) {
|
if ($initialize) {
|
||||||
// Запрошена инициализация
|
// Запрошена инициализация
|
||||||
|
|
||||||
if (isset($arangodb)) {
|
if (isset($arangodb)) {
|
||||||
|
@ -71,7 +71,7 @@ class core extends model
|
||||||
// Инициализация соединения с базой данных по умолчанию
|
// Инициализация соединения с базой данных по умолчанию
|
||||||
$this->__get('arangodb');
|
$this->__get('arangodb');
|
||||||
}
|
}
|
||||||
} */
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
return [
|
return [
|
||||||
'clientId' => '',
|
'endpoint' => 'unix:///var/run/arangodb3/arango.sock',
|
||||||
'clientSecret' => '',
|
'database' => '',
|
||||||
'redirectUri' => ''
|
'name' => '',
|
||||||
|
'password' => ''
|
||||||
];
|
];
|
||||||
|
|
|
@ -1,8 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
return [
|
return [
|
||||||
'endpoint' => 'unix:///var/run/arangodb3/arango.sock',
|
'clientId' => '',
|
||||||
'database' => '',
|
'clientSecret' => '',
|
||||||
'name' => '',
|
'redirectUri' => ''
|
||||||
'password' => ''
|
|
||||||
];
|
];
|
||||||
|
|
|
@ -1,8 +0,0 @@
|
||||||
<?php
|
|
||||||
|
|
||||||
return [
|
|
||||||
'endpoint' => 'unix:///var/run/arangodb3/arango.sock',
|
|
||||||
'database' => '',
|
|
||||||
'name' => '',
|
|
||||||
'password' => ''
|
|
||||||
];
|
|
|
@ -0,0 +1,6 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
'state' => 'OPTIONAL_CUSTOM_CONFIGURED_STATE',
|
||||||
|
'scope' => ['identify', 'email']
|
||||||
|
];
|
Loading…
Reference in New Issue