Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 27205bd

Browse files
Cleanup DOMAttr::isId() (#15016)
1 parent 5905857 commit 27205bd

File tree

1 file changed

+3
-13
lines changed

1 file changed

+3
-13
lines changed

‎ext/dom/attr.c‎

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -193,22 +193,12 @@ Since: DOM Level 3
193193
*/
194194
PHP_METHOD(DOMAttr, isId)
195195
{
196-
zval *id;
197196
dom_object *intern;
198197
xmlAttrPtr attrp;
199198

200-
id = ZEND_THIS;
201-
if (zend_parse_parameters_none() == FAILURE) {
202-
RETURN_THROWS();
203-
}
204-
205-
DOM_GET_OBJ(attrp, id, xmlAttrPtr, intern);
206-
207-
if (attrp->atype == XML_ATTRIBUTE_ID) {
208-
RETURN_TRUE;
209-
} else {
210-
RETURN_FALSE;
211-
}
199+
ZEND_PARSE_PARAMETERS_NONE();
200+
DOM_GET_OBJ(attrp, ZEND_THIS, xmlAttrPtr, intern);
201+
RETURN_BOOL(attrp->atype == XML_ATTRIBUTE_ID);
212202
}
213203
/* }}} end dom_attr_is_id */
214204

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /