Refactored according to the resolver-php-server changes.