$this->id, 'workout_id' => $this->workout_id, 'position' => $this->position, 'sets' => $this->sets, 'reps' => $this->reps, 'weight' => $this->weight !== null ? (float) $this->weight : null, 'rest_seconds' => $this->rest_seconds, 'notes' => $this->notes, 'exercise' => new ExerciseResource($this->whenLoaded('exercise')), ]; } }