| Conditions | 2 | 
| Paths | 2 | 
| Total Lines | 12 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Tests | 0 | 
| CRAP Score | 6 | 
| Changes | 0 | ||
| 1 | <?php  | 
            ||
| 24 | protected function populateSettings(Provider $record): Provider  | 
            ||
| 25 |     { | 
            ||
| 26 |         $allSettings = Craft::$app->getRequest()->getBodyParam('settings'); | 
            ||
| 27 | |||
| 28 |         if (!is_array($allSettings)) { | 
            ||
| 29 | $allSettings = [$allSettings];  | 
            ||
| 30 | }  | 
            ||
| 31 | |||
| 32 | $record->settings = $allSettings[$record->class] ?? null;;  | 
            ||
| 33 | |||
| 34 | return $record;  | 
            ||
| 35 | }  | 
            ||
| 36 | }  | 
            ||
| 37 |