| Conditions | 5 | 
| Paths | 5 | 
| Total Lines | 22 | 
| Code Lines | 10 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Tests | 10 | 
| CRAP Score | 5 | 
| Changes | 1 | ||
| Bugs | 0 | Features | 0 | 
| 1 | <?php  | 
            ||
| 19 | 15 | public function extractMessage($object, $languageIso)  | 
            |
| 
                                                                                                    
                        
                         | 
                |||
| 20 |     { | 
            ||
| 21 | // TODO retrieve and translate the message / remove getAsMessage  | 
            ||
| 22 | |||
| 23 | 15 |         if ($object instanceof GameResult) { | 
            |
| 24 | 3 | return $object->getAsMessage();  | 
            |
| 25 | }  | 
            ||
| 26 | |||
| 27 | 12 |         if ($object instanceof UnableToCreateUserEvent) { | 
            |
| 28 | 3 | return $object->getReason();  | 
            |
| 29 | }  | 
            ||
| 30 | |||
| 31 | 9 |         if ($object instanceof UserEvent) { | 
            |
| 32 | 3 | return $object->getAsMessage();  | 
            |
| 33 | }  | 
            ||
| 34 | |||
| 35 | 6 |         if ($object instanceof MessageParserException) { | 
            |
| 36 | 3 | return $object->getMessage();  | 
            |
| 37 | }  | 
            ||
| 38 | |||
| 39 | 3 | return null;  | 
            |
| 40 | }  | 
            ||
| 41 | }  | 
            ||
| 42 | 
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.