-
-
Notifications
You must be signed in to change notification settings - Fork 561
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Integration of Owncast with MediaCMS for live streaming #763
base: main
Are you sure you want to change the base?
Changes from 5 commits
bda4bbd
889f2c6
e246dcb
85d7165
48e2e05
aac4a9e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,7 +7,8 @@ export function ItemsListHandler( | |
first_item_request_url, | ||
request_url, | ||
itemsCountCallback, | ||
loadItemsCallback | ||
loadItemsCallback, | ||
translateCallback | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't understand what There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The idea with this is to keep the frontend as unmodified as possible. The way it does this is by having the OwnCast query's response translated into the same format as the MediaCMS server would normally return for a video item. |
||
) { | ||
const config = { | ||
maxItems: maxItems || 255, | ||
|
@@ -97,6 +98,10 @@ export function ItemsListHandler( | |
function fn(response) { | ||
waiting.requestResponse = false; | ||
|
||
if (translateCallback) { | ||
response = translateCallback(response); | ||
} | ||
|
||
if (!!!response || !!!response.data) { | ||
return; | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you're not adding a default value on settings, so this will make the process break with
Better wrap this in a try/except to ensure that it does not break
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added in latest commit