> */ public function getNodeTypes() : array { return [FuncCall::class]; } /** * @param FuncCall $node */ public function refactor(Node $node) : ?Node { if ($node->isFirstClassCallable()) { return null; } if (!$this->isName($node, 'sprintf')) { return null; } if (\count($node->getArgs()) > 1) { return null; } $firstArg = $node->getArgs()[0]; if ($firstArg->unpack) { return null; } return $firstArg->value; } }