fix(starred): demoted user wont get error when listing modules

This commit is contained in:
Carlos Jimenez Ruiz 2021-10-20 10:37:56 +02:00
parent 909fb368ce
commit 866d301410
1 changed files with 5 additions and 3 deletions

View File

@ -33,9 +33,11 @@ export default class Controller extends Component {
if (!res.data.length) return;
for (let starredModule of res.data) {
const module = this.modules.find(mod => mod.name === starredModule.moduleFk);
module.starred = true;
module.position = starredModule.position;
try {
const module = this.modules.find(mod => mod.name === starredModule.moduleFk);
module.starred = true;
module.position = starredModule.position;
} catch (error) {}
}
this.countModules();
});