[BridgeCard] Don't warn about the 'required' attribute if it is set to false

This commit is contained in:
logmanoriginal 2019-01-22 19:12:37 +01:00
parent e0db349a57
commit a29512deee

View file

@ -207,7 +207,7 @@ This bridge is not fetching its content through a secure connection</div>';
* @return string The list input field
*/
private static function getListInput($entry, $id, $name) {
if(isset($entry['required'])) {
if(isset($entry['required']) && $entry['required'] === true) {
Debug::log('The "required" attribute is not supported for lists.');
unset($entry['required']);
}
@ -272,7 +272,7 @@ This bridge is not fetching its content through a secure connection</div>';
* @return string The checkbox input field
*/
private static function getCheckboxInput($entry, $id, $name) {
if(isset($entry['required'])) {
if(isset($entry['required']) && $entry['required'] === true) {
Debug::log('The "required" attribute is not supported for checkboxes.');
unset($entry['required']);
}