Merge pull request #526 from Arthur-Milchior/field_with_space_are_empty
strip to test whether field is empty
This commit is contained in:
commit
1ef984cc2a
@ -496,9 +496,10 @@ class Editor:
|
||||
return True
|
||||
m = self.note.model()
|
||||
for c, f in enumerate(self.note.fields):
|
||||
f = f.replace("<br>", "").strip()
|
||||
notChangedvalues = {"", "<br>"}
|
||||
if previousNote and m["flds"][c]["sticky"]:
|
||||
notChangedvalues.add(previousNote.fields[c])
|
||||
notChangedvalues.add(previousNote.fields[c].replace("<br>", "").strip())
|
||||
if f not in notChangedvalues:
|
||||
return False
|
||||
return True
|
||||
|
@ -352,9 +352,7 @@ function setFields(fields) {
|
||||
oncut='onCutOrCopy(this);'
|
||||
contentEditable=true
|
||||
class=field
|
||||
>
|
||||
${f}
|
||||
</div>
|
||||
>${f}</div>
|
||||
</td>
|
||||
</tr>`;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user