Skip to content

Does not accept League\Flysystem\Filesystem in Storage/dropbox::setFlysystem #86

Description

@jasson99

When working on updating phpstan for files_external_dropbox, this error is found:

------ ----------------------------------------------------------------------------------------------------------------------------------------------------------- 
  Line   lib/Storage/Dropbox.php                                                                                                                                    
 ------ ----------------------------------------------------------------------------------------------------------------------------------------------------------- 
  79     Property OCA\Files_external_dropbox\Storage\Dropbox::$flysystem (OCA\Files_external_dropbox\Storage\Adapter) does not accept League\Flysystem\Filesystem.  
 ------ ----------------------------------------------------------------------------------------------------------------------------------------------------------- 

The function including line 79 is:

/**
	 * Initialize the storage backend with a flyssytem adapter
	 * @override
	 * @param \League\Flysystem\Filesystem $fs
	 */
	public function setFlysystem($fs) {
		$this->flysystem = $fs;
		$this->flysystem->addPlugin(new \League\Flysystem\Plugin\GetWithMetadata());
	}

And line 79 is:

		$this->flysystem = $fs;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions