Skip to content
This repository has been archived by the owner on Feb 14, 2020. It is now read-only.

Only check emptyness of attribute rule when actually enabled. #572

Merged
merged 1 commit into from
May 6, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion www/resources/scripts/arp.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ $(function () {
validateArp: function ($input, val) {
var message;
var value = val || $input.val();
if (!value || value.trim() === '') {
if ($input.prop("checked") && (!value || value.trim() === '')) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oi this could use some refactoring, but 👍 for now I guess.

message = this.translations.emptyAttribute;
} else {
$input.parents('td').find('input[type=hidden]').each(function (i) {
Expand Down