Skip to content

Commit

Permalink
JSHandle - Improve property not found error message
Browse files Browse the repository at this point in the history
  • Loading branch information
amaitland committed Mar 21, 2022
1 parent 7e33876 commit 107e4a5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/PuppeteerSharp/JSHandle.cs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ public async Task<T> GetPropertyValueAsync<T>(string propertyName)

if (property.RemoteObject.Type == RemoteObjectType.Undefined)
{
throw new PuppeteerException($"Property {propertyName} was not found.");
throw new PuppeteerException($"Property {propertyName} was not found. Property names are case sensitive e.g. innerText not innertext. Make sure to check your spelling.");
}

return await property.JsonValueAsync<T>().ConfigureAwait(false);
Expand Down

0 comments on commit 107e4a5

Please sign in to comment.