Skip to content

Commit

Permalink
Merge pull request #16 from erikgaal/patch-1
Browse files Browse the repository at this point in the history
Allow interfaces in default type replacements
  • Loading branch information
rubenvanassche authored Dec 23, 2021
2 parents 9ed42aa + 8ccc226 commit bafa5d9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/TypeScriptTransformerConfig.php
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ public function getDefaultTypeReplacements(): array
$replacements = [];

foreach ($this->defaultTypeReplacements as $class => $replacement) {
if (! class_exists($class)) {
if (! class_exists($class) && ! interface_exists($class)) {
throw InvalidDefaultTypeReplacer::classDoesNotExist($class);
}

Expand Down

0 comments on commit bafa5d9

Please sign in to comment.