Skip to content

Commit

Permalink
Fix some phpstan issues
Browse files Browse the repository at this point in the history
  • Loading branch information
magicsunday committed Nov 19, 2023
1 parent f2ceb4a commit 155726a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/Module.php
Original file line number Diff line number Diff line change
Expand Up @@ -533,7 +533,9 @@ private function getStylesheets(): array
*/
private function getExportStylesheets(): array
{
$stylesheets = app(ModuleThemeInterface::class)->stylesheets();
/** @var ModuleThemeInterface $moduleTheme */
$moduleTheme = app(ModuleThemeInterface::class);
$stylesheets = $moduleTheme->stylesheets();
$stylesheets[] = $this->assetUrl('css/svg.css');

return $stylesheets;
Expand Down
3 changes: 2 additions & 1 deletion src/Traits/IndividualTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,8 @@ public function getPreferredName(DOMXPath $xpath): string
*/
public function getAlternateName(Individual $individual): string
{
if ($individual->canShowName()
if (
$individual->canShowName()
&& ($individual->getPrimaryName() !== $individual->getSecondaryName())
) {
$allNames = $individual->getAllNames();
Expand Down

0 comments on commit 155726a

Please sign in to comment.