Skip to content

Commit

Permalink
Merge pull request #23 from Avarei/fix/silly-mistake
Browse files Browse the repository at this point in the history
fix mistake from 18acad4
  • Loading branch information
Avarei committed Jul 4, 2024
2 parents 5ffc981 + d0b1bc8 commit 2e42033
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkl/crossplane.contrib/crossplane.pkl
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,8 @@ local function convert(value: Any, type: reflect.Type?): Any =
let (template = getResourceTemplate(value, customResourceTemplates)) // TODO: replace customResourceTemplate with actual val
value
.toMap()
.map((k, v) -> Pair(k, convert(v, reflect.Class(pkl.getClass()).properties.getOrNull(k)?.type)))
.toTyped(pkl.getClass())
.map((k, v) -> Pair(k, convert(v, reflect.Class(template.getClass()).properties.getOrNull(k)?.type)))
.toTyped(template.getClass())
else if (value is Mapping && referent is reflect.Class && referent.isSubclassOf(typedClass))
value
.toMap()
Expand Down

0 comments on commit 2e42033

Please sign in to comment.