mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-11-16 14:48:11 +00:00
Fix phpstan issues.
This commit is contained in:
@@ -327,12 +327,12 @@ class ReportController extends Controller
|
||||
*
|
||||
* @param ReportFormRequest $request
|
||||
*
|
||||
* @return RedirectResponse|Redirector
|
||||
* @return RedirectResponse|Redirector|View
|
||||
*
|
||||
* @throws FireflyException
|
||||
*
|
||||
*/
|
||||
public function postIndex(ReportFormRequest $request)
|
||||
public function postIndex(ReportFormRequest $request): RedirectResponse|Redirector|View
|
||||
{
|
||||
// report type:
|
||||
$reportType = $request->get('report_type');
|
||||
|
||||
@@ -107,9 +107,9 @@ class SelectController extends Controller
|
||||
*
|
||||
* @param Rule $rule
|
||||
*
|
||||
* @return Factory|View
|
||||
* @return Factory|View|RedirectResponse
|
||||
*/
|
||||
public function selectTransactions(Rule $rule)
|
||||
public function selectTransactions(Rule $rule): Factory|View|RedirectResponse
|
||||
{
|
||||
if (false === $rule->active) {
|
||||
session()->flash('warning', trans('firefly.cannot_fire_inactive_rules'));
|
||||
|
||||
@@ -166,11 +166,8 @@ class InstallController extends Controller
|
||||
*/
|
||||
public function keys(): void
|
||||
{
|
||||
// switch on PHP version.
|
||||
$keys = [];
|
||||
// switch on class existence.
|
||||
app('log')->info('Will run PHP8 code.');
|
||||
$keys = RSA::createKey(4096);
|
||||
|
||||
$key = RSA::createKey(4096);
|
||||
|
||||
[$publicKey, $privateKey] = [
|
||||
Passport::keyPath('oauth-public.key'),
|
||||
@@ -181,7 +178,7 @@ class InstallController extends Controller
|
||||
return;
|
||||
}
|
||||
|
||||
file_put_contents($publicKey, $keys['publickey']);
|
||||
file_put_contents($privateKey, $keys['privatekey']);
|
||||
file_put_contents($publicKey, (string) $key->getPublicKey());
|
||||
file_put_contents($privateKey, $key->toString('PKCS1'));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user