Skip to content
This repository has been archived by the owner on Aug 1, 2023. It is now read-only.

Commit

Permalink
remove toVector() for HHVM 4.29+
Browse files Browse the repository at this point in the history
  • Loading branch information
jjergus committed Oct 24, 2019
1 parent 7998913 commit f80439f
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
3 changes: 1 addition & 2 deletions src/RequestParametersCodegenBuilder.hack
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,7 @@ final class RequestParametersCodegenBuilder<T as RequestParametersBase>
$parameter['optional'] ? 'Optional' : '',
$getter_spec['accessorSuffix'],
),
$getter_spec['args']->map($arg ==> $arg->render($param_spec))
->toVector(),
$getter_spec['args']->map($arg ==> $arg->render($param_spec)),
/* semicolon at end = */ false,
)
->add(',');
Expand Down
2 changes: 1 addition & 1 deletion src/UriBuilderCodegenBuilder.hack
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ extends RequestParametersCodegenBuilderBase<UriBuilderCodegenBase<T>> {
$param,
\sprintf('$parameters[\'%s\']', $param->getName()),
),
)->toVector(),
),
/* semicolon at end = */ false,
);
}
Expand Down
7 changes: 4 additions & 3 deletions tests/examples/GetRequestExampleController.hack
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,10 @@ implements

final public static function __getParametersSpec(
): ImmVector<shape('spec' => RequestParameter, 'optional' => bool)> {
$params = static::getUriPattern()->getParameters()->map(
$param ==> shape('spec' => $param, 'optional' => false),
)->toVector();
$params = new Vector(
static::getUriPattern()->getParameters()
->map($param ==> shape('spec' => $param, 'optional' => false)),
);
$params[] = shape(
'spec' => new StringRequestParameter(
StringRequestParameterSlashes::WITHOUT_SLASHES,
Expand Down

0 comments on commit f80439f

Please sign in to comment.