Skip to content

ideas for next version: error handling and return types #64

@tacman

Description

@tacman
 public function getPhotos(
        $photosetId,
        $userId = null,
        $extras = null,
        $perPage = null,
        $page = null,
        $privacyFilter = null,
        $media = null
    ) 

With PHP 8, we'll want to add a return type to the methods. Currently in getPhotos(), this is array|bool, but we could make it ?array, and return null instead of false.

It appears that returning false indicates some sort of error, though, so perhaps that's not the best approach.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions