Skip to content

fixup! reformat code base#10

Closed
jtojnar wants to merge 1 commit intodvikan:reformat-codebase-v4from
jtojnar:reformat-codebase-v3
Closed

fixup! reformat code base#10
jtojnar wants to merge 1 commit intodvikan:reformat-codebase-v4from
jtojnar:reformat-codebase-v3

Conversation

@jtojnar
Copy link

@jtojnar jtojnar commented Jul 1, 2022

$ composer require --dev friendsofphp/php-cs-fixer

$ echo >.php-cs-fixer.dist.php "<?php

$finder = PhpCsFixer\Finder::create()
    ->exclude('squizlabsD')
    ->in(__DIR__);

$rules = [
    '@psr12' => true,
    // buggy, duplicates existing comment sometimes
    'no_break_comment' => false,
    'array_syntax' => true,
    'lowercase_static_reference' => true,
    'visibility_required' => false,
];

$config = new PhpCsFixer\Config();

return $config
    ->setRules($rules)
    ->setFinder($finder);
"

$ vendor/bin/php-cs-fixer --version
PHP CS Fixer 3.8.0 BerSzcz against war! by Fabien Potencier and Dariusz Ruminski.
PHP runtime: 7.4.30

$ vendor/bin/php-cs-fixer fix

$ composer require --dev friendsofphp/php-cs-fixer

$ echo >.php-cs-fixer.dist.php "<?php

$finder = PhpCsFixer\Finder::create()
    ->exclude('squizlabsD')
    ->in(__DIR__);

$rules = [
    '@psr12' => true,
    // buggy, duplicates existing comment sometimes
    'no_break_comment' => false,
    'array_syntax' => true,
    'lowercase_static_reference' => true,
    'visibility_required' => false,
];

$config = new PhpCsFixer\Config();

return $config
    ->setRules($rules)
    ->setFinder($finder);
"

$ vendor/bin/php-cs-fixer --version
PHP CS Fixer 3.8.0 BerSzcz against war! by Fabien Potencier and Dariusz Ruminski.
PHP runtime: 7.4.30

$ vendor/bin/php-cs-fixer fix
@jtojnar jtojnar force-pushed the reformat-codebase-v3 branch from fb25a1e to 904e258 Compare July 1, 2022 00:51
@jtojnar jtojnar changed the base branch from reformat-codebase-v3 to reformat-codebase-v4 July 1, 2022 00:52
@jtojnar
Copy link
Author

jtojnar commented Jul 1, 2022

Superseded by RSS-Bridge#2875

@jtojnar jtojnar closed this Jul 1, 2022
@jtojnar jtojnar deleted the reformat-codebase-v3 branch July 1, 2022 13:25
dvikan pushed a commit that referenced this pull request Feb 8, 2026
Won't work without API keys anymore. The change is code-wise easy to do, while scraping the HTML would be cumbersome.

 Bridge returned error 401! (20449)
2025-12-27 03:26:04

https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/401
Details
Type: HttpException
Code: 401
Message: https://gelbooru.com/index.php?&page=dapi&s=post&q=index&json=1&pid=0&limit=&tags= resulted in 401 Unauthorized
File: lib/http.php
Line: 34
Trace
#0 index.php(73): RssBridge->main()
#1 lib/RssBridge.php(39): RssBridge->{closure}()
#2 lib/RssBridge.php(37): BasicAuthMiddleware->__invoke()
#3 middlewares/BasicAuthMiddleware.php(13): RssBridge->{closure}()
#4 lib/RssBridge.php(37): CacheMiddleware->__invoke()
#5 middlewares/CacheMiddleware.php(44): RssBridge->{closure}()
#6 lib/RssBridge.php(37): ExceptionMiddleware->__invoke()
#7 middlewares/ExceptionMiddleware.php(17): RssBridge->{closure}()
#8 lib/RssBridge.php(37): SecurityMiddleware->__invoke()
#9 middlewares/SecurityMiddleware.php(19): RssBridge->{closure}()
#10 lib/RssBridge.php(37): MaintenanceMiddleware->__invoke()
#11 middlewares/MaintenanceMiddleware.php(10): RssBridge->{closure}()
#12 lib/RssBridge.php(37): TokenAuthenticationMiddleware->__invoke()
RSS-Bridge#13 middlewares/TokenAuthenticationMiddleware.php(10): RssBridge->{closure}()
RSS-Bridge#14 lib/RssBridge.php(34): DisplayAction->__invoke()
RSS-Bridge#15 actions/DisplayAction.php(54): DisplayAction->createResponse()
RSS-Bridge#16 actions/DisplayAction.php(89): GelbooruBridge->collectData()
RSS-Bridge#17 bridges/GelbooruBridge.php(80): getContents()
RSS-Bridge#18 lib/contents.php(131): HttpException::fromResponse()
RSS-Bridge#19 lib/http.php(34)

Context
Query: action=display&bridge=GelbooruBridge&p=0&t=&l=&format=Html
Version: 2025-08-05
OS: Linux
PHP: 8.2.29


Co-authored-by: Mynacol <git@mynacol.xyz>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant