Try and get media uploading working again
This commit is contained in:
parent
f2b6beb3b8
commit
fbf937102e
3 changed files with 7 additions and 5 deletions
|
@ -55,8 +55,8 @@ class MicropubClientController extends Controller
|
|||
*/
|
||||
public function processMedia(Request $request)
|
||||
{
|
||||
if ($request->hasFile('file') == false) {
|
||||
return back()->with('error', 'No file uploaded');
|
||||
if ($request->hasFile('files') == false) {
|
||||
return back()->with('error', 'No files uploaded');
|
||||
}
|
||||
|
||||
$user = IndieWebUser::where('me', $request->session()->get('me'))->firstOrFail();
|
||||
|
@ -65,7 +65,7 @@ class MicropubClientController extends Controller
|
|||
}
|
||||
|
||||
$mediaURLs = [];
|
||||
foreach ($request->file('file') as $file) {
|
||||
foreach ($request->file('files') as $file) {
|
||||
try {
|
||||
$response = $this->guzzleClient->request('POST', $user->mediaEndpoint, [
|
||||
'headers' => [
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
# Changelog
|
||||
|
||||
## Version {next}
|
||||
- Remove some file checking to see if we can get uploads working again
|
||||
|
||||
## Version 0.5.25 (2017-07-20)
|
||||
- Update npm dev dependencies to use local installs over global installs
|
||||
- Improve contact info display in note mentions by using hovercards
|
||||
|
|
|
@ -90,9 +90,8 @@
|
|||
<div>
|
||||
<label for="media" accesskey="m">Media: </label>
|
||||
<input type="file"
|
||||
accept="audio/*,video/*,image/*,application/pdf,.md"
|
||||
value="Upload"
|
||||
name="file[]"
|
||||
name="files[]"
|
||||
id="media"
|
||||
multiple
|
||||
>
|
||||
|
|
Loading…
Add table
Reference in a new issue