| Conditions | 2 | 
| Paths | 2 | 
| Total Lines | 9 | 
| Code Lines | 4 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Tests | 0 | 
| CRAP Score | 6 | 
| Changes | 1 | ||
| Bugs | 0 | Features | 0 | 
| 1 | <?php  | 
            ||
| 41 | public function get(string $mediaId)  | 
            ||
| 42 |     { | 
            ||
| 43 |         $response = $this->requestRaw('cgi-bin/material/get_material', 'POST', ['json' => ['media_id' => $mediaId]]); | 
            ||
| 44 | |||
| 45 |         if (false !== stripos($response->getHeaderLine('Content-disposition'), 'attachment')) { | 
            ||
| 46 | return StreamResponse::buildFromPsrResponse($response);  | 
            ||
| 47 | }  | 
            ||
| 48 | |||
| 49 |         return $this->castResponseToType($response, $this->app['config']->get('response_type')); | 
            ||
| 50 | }  | 
            ||
| 52 |