Skip to content

Commit

Permalink
Use constant to ensure consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
lehecht committed Dec 5, 2024
1 parent 3ac3fc1 commit dda661a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion resources/assets/js/label-trees/components/labelTrees.vue
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import Keyboard from '../../core/keyboard';
import LabelTree from './labelTree';
import Typeahead from './labelTypeahead';
import { MAX_FAVOURITES } from '../constants';
/**
* A component that displays a list of label trees.
Expand Down Expand Up @@ -110,7 +111,7 @@ export default {
return this.favourites.map((label) => label.id);
},
canHaveMoreFavourites() {
return this.favourites.length < 10;
return this.favourites.length < MAX_FAVOURITES;
},
hasFavourites() {
return this.favourites.length > 0;
Expand Down

0 comments on commit dda661a

Please sign in to comment.