the browser-facing portion of osu!
at master 22 lines 661 B view raw
1<?php 2 3// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the GNU Affero General Public License v3.0. 4// See the LICENCE file in the repository root for full licence text. 5 6namespace App\Transformers; 7 8use App\Models\ScoreToken; 9 10class ScoreTokenTransformer extends TransformerAbstract 11{ 12 public function transform(ScoreToken $scoreToken) 13 { 14 return [ 15 'beatmap_id' => $scoreToken->beatmap_id, 16 'created_at' => $scoreToken->created_at_json, 17 'id' => $scoreToken->getKey(), 18 'playlist_item_id' => $scoreToken->playlist_item_id, 19 'user_id' => $scoreToken->user_id, 20 ]; 21 } 22}