Fixed an issue where InputActionAsset.FindAction(string, bool) would throw System.NullReferenceException instead of returning null if searching for a non-existent action with an explicit action path and using throwIfNotFound: false, e.g. searching for "Map/Action" when InputActionMap "Map" exists but no InputAction named "Action" exists within that map ISXB-895.
Changes made
Added a null check to actions array for path-evaluation in FindActions.
Checklist
Before review:
[x] Changelog entry added.
Explains the change in Changed, Fixed, Added sections.
For API change contains an example snippet and/or migration example.
FogBugz ticket attached, example ([case %number%](https://issuetracker.unity3d.com/issues/...)).
FogBugz is marked as "Resolved" with next release version correctly set.
Description
Fixed an issue where
InputActionAsset.FindAction(string, bool)
would throwSystem.NullReferenceException
instead of returningnull
if searching for a non-existent action with an explicit action path and usingthrowIfNotFound: false
, e.g. searching for "Map/Action" whenInputActionMap
"Map" exists but noInputAction
named "Action" exists within that map ISXB-895.Changes made
Added a null check to actions array for path-evaluation in
FindActions
.Checklist
Before review:
Changed
,Fixed
,Added
sections.([case %number%](https://issuetracker.unity3d.com/issues/...))
.Actions_CanAttemptToLookUpNonExistentActionInAssetByPath
.During merge:
NEW: ___
.FIX: ___
.DOCS: ___
.CHANGE: ___
.RELEASE: 1.1.0-preview.3
.