Move privacyPreference to utils

This commit is contained in:
Thibaut Girka
2018-07-12 11:33:11 +02:00
committed by ThibG
parent cd05378b59
commit d8b13b46f7
2 changed files with 6 additions and 5 deletions

View File

@ -0,0 +1,5 @@
export const order = ['public', 'unlisted', 'private', 'direct'];
export function privacyPreference (a, b) {
return order[Math.max(order.indexOf(a), order.indexOf(b), 0)];
};