Skip to content

Commit

Permalink
Merge pull request #1427 from nextcloud/use-php-8-4
Browse files Browse the repository at this point in the history
chore: Bump max-version of PHP to 8.4
  • Loading branch information
juliusknorr authored Nov 26, 2024
2 parents ae0239a + 24c69e2 commit 63b5439
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion appinfo/info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ The Notes app is a distraction free notes taking app for [Nextcloud](https://www
<repository type="git">https://github.com/nextcloud/notes.git</repository>
<screenshot small-thumbnail="https://raw.githubusercontent.com/nextcloud/screenshots/master/apps/Notes/notes-thumbnail.jpg">https://raw.githubusercontent.com/nextcloud/screenshots/master/apps/Notes/notes.png</screenshot>
<dependencies>
<php min-version="8.0" max-version="8.3"/>
<php min-version="8.0" max-version="8.4"/>
<nextcloud min-version="28" max-version="31"/>
</dependencies>
<repair-steps>
Expand Down
4 changes: 2 additions & 2 deletions lib/AppInfo/DashboardWidget.php
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public function getWidgetButtons(string $userId): array {
public function getItems(string $userId, ?string $since = null, int $limit = 7): array {
$notes = $this->notesService->getTopNotes($userId);
$notes = array_slice($notes, 0, $limit);
return array_map(function (Note $note) {
return array_values(array_map(function (Note $note): WidgetItem {
$excerpt = '';
try {
$excerpt = $note->getExcerpt();
Expand All @@ -109,7 +109,7 @@ public function getItems(string $userId, ?string $since = null, int $limit = 7):
? $this->url->getAbsoluteURL($this->url->imagePath('core', 'actions/starred.svg'))
: $this->getIconUrl();
return new WidgetItem($note->getTitle(), $excerpt, $link, $icon, (string)$note->getModified());
}, $notes);
}, $notes));
}

public function getIconUrl(): string {
Expand Down
4 changes: 4 additions & 0 deletions lib/Service/TagService.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ public function __construct(ITagManager $tagManager) {
$this->tagger = $tagManager->load('files');
}

/**
* @param list<int> $fileIds
* @return void
*/
public function loadTags(array $fileIds) : void {
$this->cachedTags = $this->tagger->getTagsForObjects($fileIds);
}
Expand Down

0 comments on commit 63b5439

Please sign in to comment.