mirror of
https://github.com/SociallyDev/Spaces-API.git
synced 2025-08-19 21:03:44 -07:00
🚀 Add direct upload method
This commit is contained in:
parent
8ff8498a22
commit
68ede3758a
1 changed files with 6 additions and 0 deletions
|
@ -297,6 +297,12 @@ class Space
|
|||
return new File($this, $filename, [], false);
|
||||
}
|
||||
|
||||
public function upload(string $filename, $content, string $privacy = 'public-read', array $params = []): File
|
||||
{
|
||||
$this->s3->upload($this->name, $filename, $content, $privacy, $params);
|
||||
return new File($this, $filename, [], false);
|
||||
}
|
||||
|
||||
/**
|
||||
* Upload a file
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue