X-Git-Url: https://git.localhorst.tv/?a=blobdiff_plain;ds=sidebyside;f=resources%2Fjs%2Fcomponents%2Fepisodes%2FRestreamAddForm.js;h=c09b92b8d817125369f79dc2b386492becdc8d62;hb=2ba39c5f4632579146d2663d82149a156a4e96c1;hp=7cbb87d538e17b2102ebe95df68edfe9c78bba23;hpb=5a575dc29f3af10f1d8e142ff9e1c6ccdfa3b075;p=alttp.git
diff --git a/resources/js/components/episodes/RestreamAddForm.js b/resources/js/components/episodes/RestreamAddForm.js
index 7cbb87d..c09b92b 100644
--- a/resources/js/components/episodes/RestreamAddForm.js
+++ b/resources/js/components/episodes/RestreamAddForm.js
@@ -7,7 +7,9 @@ import { useTranslation } from 'react-i18next';
import DialogEpisode from './DialogEpisode';
import ToggleSwitch from '../common/ToggleSwitch';
import laravelErrorsToFormik from '../../helpers/laravelErrorsToFormik';
-import { withUser } from '../../helpers/UserContext';
+import { withUser } from '../../hooks/user';
+
+const channelCompare = (a, b) => a.channel.title.localeCompare(b.channel.title);
const RestreamAddForm = ({
episode,
@@ -35,7 +37,7 @@ const RestreamAddForm = ({
value={values.channel_id || 0}
>
- {((user && user.channel_crews) || []).map(c =>
+ {((user && user.channel_crews) || []).sort(channelCompare).map(c =>