1
0
Fork 1
mirror of https://github.com/pixelfed/pixelfed.git synced 2024-12-30 19:55:10 +00:00
pixelfed/app/Http/Controllers/ProfileSponsorController.php

18 lines
345 B
PHP
Raw Normal View History

2019-07-12 01:53:14 +00:00
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\ProfileSponsor;
use Auth;
class ProfileSponsorController extends Controller
{
public function get(Request $request, $id)
{
2019-08-17 07:41:35 +00:00
$profile = ProfileSponsor::whereProfileId($id)->first();
$res = $profile ? $profile->sponsors : [];
return response()->json($res);
2019-07-12 01:53:14 +00:00
}
}