Skip to content

Commit

Permalink
fix: array with array of items throws error and only object is suppor…
Browse files Browse the repository at this point in the history
…ted (#117)
  • Loading branch information
derberg authored Nov 9, 2020
1 parent 32517f7 commit 02236d7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion partials/schema-prop.html
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,8 @@
{% endif %}

{% if prop.type() === 'array' %}
{% set arrayItemsProps = (prop.items().properties() if prop.items() else null) %}

{% set arrayItemsProps = prop.items().properties() if prop.items() and not prop.items() | isArray else null %}
{% if prop.items() and arrayItemsProps | isEmpty %}
<p class="pl-6 mb-2 text-xs font-bold uppercase text-grey-darker">Items:</p>
{% if prop.items() | isArray %}
Expand Down

0 comments on commit 02236d7

Please sign in to comment.