| Conditions | 1 |
| Paths | 1 |
| Total Lines | 15 |
| Code Lines | 10 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 9 |
| CRAP Score | 1.006 |
| Changes | 0 | ||
| 1 | <?php |
||
| 46 | 1 | protected function execute(InputInterface $input, OutputInterface $output) |
|
| 47 | { |
||
| 48 | 1 | $userId = (int)$input->getArgument('user'); |
|
| 49 | 1 | $roles = (string)$input->getArgument('roles'); |
|
| 50 | |||
| 51 | 1 | $token = $this->token->addToken($userId, explode(',', $roles)); |
|
| 52 | 1 | $output->writeln( |
|
| 53 | 1 | sprintf( |
|
| 54 | 1 | 'Created token %s for user %d with roles: %s', |
|
| 55 | $token, |
||
| 56 | $userId, |
||
| 57 | 1 | $roles |
|
| 58 | ) |
||
| 59 | ); |
||
| 60 | 1 | } |
|
| 61 | } |
||
| 62 |