Skip to content

Commit

Permalink
Fixed a name clash
Browse files Browse the repository at this point in the history
  • Loading branch information
Mnemotechnician committed Jun 28, 2022
1 parent b241fce commit 52e60fa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/src/main/kotlin/ElementUtil.kt
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ inline fun <reified T: Element> Element.findOrNull(elementName: String? = null):
*
* @throws IllegalArgumentException if there's no such element.
*/
inline fun <reified T: Element> Element.find(elementName: String? = null): T {
inline fun <reified T: Element> Element.findElement(elementName: String? = null): T {
return findOrNull(elementName)
?: throw IllegalArgumentException("Element with type ${T::class}${if (elementName == null) "" else " and name '$elementName'"} was not found")
}

0 comments on commit 52e60fa

Please sign in to comment.