mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-01-01 13:14:16 +08:00
fix(templates): fix two bugs breaking templates plugin rename and search
This commit is contained in:
parent
6a735da033
commit
2849cce077
2 changed files with 2 additions and 2 deletions
|
@ -43,7 +43,7 @@ class TemplatePicker extends React.Component {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
_onSearchValueChange() {
|
_onSearchValueChange = () => {
|
||||||
const newSearch = event.target.value;
|
const newSearch = event.target.value;
|
||||||
return this.setState({
|
return this.setState({
|
||||||
searchValue: newSearch,
|
searchValue: newSearch,
|
||||||
|
|
|
@ -163,7 +163,7 @@ class TemplateStore extends NylasStore {
|
||||||
|
|
||||||
_getTemplate(name, id) {
|
_getTemplate(name, id) {
|
||||||
for (const template of this._items) {
|
for (const template of this._items) {
|
||||||
if ((template.name === name || name === null) && (template.id === id || id === null)) {
|
if ((template.name === name || name == null) && (template.id === id || id == null)) {
|
||||||
return template;
|
return template;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue