Skip to content

Commit 94bcd63

Browse files
Merge pull request #264826 from mumian/0131-first-function
Add more details to the first() function
2 parents 2097554 + 8e74f49 commit 94bcd63

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

articles/azure-resource-manager/bicep/bicep-functions-string.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: Bicep functions - string
33
description: Describes the functions to use in a Bicep file to work with strings.
44
ms.topic: conceptual
55
ms.custom: devx-track-bicep
6-
ms.date: 07/07/2023
6+
ms.date: 01/31/2024
77
---
88

99
# String functions for Bicep
@@ -414,7 +414,7 @@ The output from the preceding example with the default values is:
414414

415415
`first(arg1)`
416416

417-
Returns the first character of the string, or first element of the array.
417+
Returns the first character of the string, or first element of the array. If an empty string is given, the function results in an empty string. In the case of an empty array, the function returns `null`.
418418

419419
Namespace: [sys](bicep-functions.md#namespaces-for-functions).
420420

articles/azure-resource-manager/templates/template-functions-string.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: Template functions - string
33
description: Describes the functions to use in an Azure Resource Manager template (ARM template) to work with strings.
44
ms.topic: conceptual
55
ms.custom: devx-track-arm-template
6-
ms.date: 05/22/2023
6+
ms.date: 01/31/2024
77
---
88

99
# String functions for ARM templates
@@ -358,7 +358,7 @@ The output from the preceding example with the default values is:
358358

359359
`first(arg1)`
360360

361-
Returns the first character of the string, or first element of the array.
361+
Returns the first character of the string, or first element of the array. If an empty string is given, the function results in an empty string. In the case of an empty array, the function returns `null`.
362362

363363
In Bicep, use the [first](../bicep/bicep-functions-string.md#first) function.
364364

0 commit comments

Comments
 (0)