diff options
author | Romain d'Alverny <rdalverny@gmail.com> | 2022-01-11 12:36:17 +0100 |
---|---|---|
committer | Romain d'Alverny <rdalverny@gmail.com> | 2022-01-11 12:36:17 +0100 |
commit | 138865bbde25bb6193930c98e30c33913d19e367 (patch) | |
tree | 626e8e26dd4f4776ce9f8cd743987f08377127ed /atom.php | |
parent | 5f2b708377aec4bc5f1d731dfbb50557552d0482 (diff) | |
download | planet-138865bbde25bb6193930c98e30c33913d19e367.tar planet-138865bbde25bb6193930c98e30c33913d19e367.tar.gz planet-138865bbde25bb6193930c98e30c33913d19e367.tar.bz2 planet-138865bbde25bb6193930c98e30c33913d19e367.tar.xz planet-138865bbde25bb6193930c98e30c33913d19e367.zip |
Install code QA helpers, enforce PSR2
Installs phpcs, phpmd, parallel-lint, phpstan.
Diffstat (limited to 'atom.php')
-rw-r--r-- | atom.php | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -2,7 +2,9 @@ include_once(__DIR__.'/app/app.php'); include_once(__DIR__.'/app/classes/Cache.php'); -if ($Planet->loadOpml(__DIR__.'/custom/people.opml') == 0) exit; +if ($Planet->loadOpml(__DIR__.'/custom/people.opml') == 0) { + exit; +} $Planet->loadFeeds(); $items = $Planet->getItems(); @@ -22,8 +24,7 @@ echo '<?xml version="1.0" encoding="UTF-8" ?>'; <author><name><?=htmlspecialchars($PlanetConfig->getName())?></name></author> <?php $count = 0; ?> -<?php foreach ($items as $item): ?> - +<?php foreach ($items as $item) : ?> <entry> <title type="html"><?=htmlspecialchars($item->get_feed()->getName())?> : <?=htmlspecialchars($item->get_title())?></title> <id><?=htmlspecialchars($item->get_permalink())?></id> @@ -35,7 +36,9 @@ echo '<?xml version="1.0" encoding="UTF-8" ?>'; <content type="html"><![CDATA[<?=$item->get_content()?>]]></content> </entry> -<?php if (++$count == $limit) break; ?> + <?php if (++$count == $limit) { + break; + } ?> <?php endforeach; ?> </feed> |