From 4df934ac3d17fb83324292e1befdda46f1f622b2 Mon Sep 17 00:00:00 2001 From: Matthias Mohr Date: Tue, 21 Jan 2020 14:37:20 +0100 Subject: [PATCH] Pass labels separately from indices to callbacks. --- array_apply.json | 12 ++++++++---- array_filter.json | 12 ++++++++---- 2 files changed, 16 insertions(+), 8 deletions(-) diff --git a/array_apply.json b/array_apply.json index 2152d433..5b75e115 100644 --- a/array_apply.json +++ b/array_apply.json @@ -34,12 +34,16 @@ }, { "name": "index", - "description": "The zero-based index or the label of the current element being processed. Labels take preference over indices.", + "description": "The zero-based index of the current element being processed.", "required": true, + "schema": { + "type": "integer" + } + }, + { + "name": "label", + "description": "The label of the current element being processed. Only populated for labeled arrays.", "schema": [ - { - "type": "number" - }, { "type": "string" } diff --git a/array_filter.json b/array_filter.json index fbaff1be..cae9588e 100644 --- a/array_filter.json +++ b/array_filter.json @@ -35,12 +35,16 @@ }, { "name": "index", - "description": "The zero-based index or the label of the current element being processed. Labels take preference over indices.", + "description": "The zero-based index of the current element being processed.", "required": true, + "schema": { + "type": "integer" + } + }, + { + "name": "label", + "description": "The label of the current element being processed. Only populated for labeled arrays.", "schema": [ - { - "type": "number" - }, { "type": "string" }