commit
bfbe69a861
3 changed files with 5 additions and 9 deletions
|
@ -61,7 +61,7 @@ export let FileActions = React.createClass({
|
||||||
path: React.PropTypes.string,
|
path: React.PropTypes.string,
|
||||||
hidden: React.PropTypes.bool,
|
hidden: React.PropTypes.bool,
|
||||||
deleteChecked: React.PropTypes.bool,
|
deleteChecked: React.PropTypes.bool,
|
||||||
onRemove: React.PropTypes.function,
|
onRemove: React.PropTypes.func,
|
||||||
},
|
},
|
||||||
getInitialState: function() {
|
getInitialState: function() {
|
||||||
return {
|
return {
|
||||||
|
@ -191,7 +191,7 @@ export let FileActions = React.createClass({
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<section className="file-actions">
|
<section className="file-actions">
|
||||||
{this.props.metadata.content_type.startsWith('video/') ? <WatchLink streamName={this.props.streamName} /> : null}
|
{(this.props.metadata.content_type && this.props.metadata.content_type.startsWith('video/')) ? <WatchLink streamName={this.props.streamName} /> : null}
|
||||||
{this.state.fileInfo !== null || this.state.fileInfo.isMine ?
|
{this.state.fileInfo !== null || this.state.fileInfo.isMine ?
|
||||||
<div className="button-container">{linkBlock}</div>
|
<div className="button-container">{linkBlock}</div>
|
||||||
: null}
|
: null}
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
|
import {Icon} from './common.js';
|
||||||
|
|
||||||
var requiredFieldWarningStyle = {
|
var requiredFieldWarningStyle = {
|
||||||
color: '#cc0000',
|
color: '#cc0000',
|
||||||
|
|
|
@ -308,12 +308,7 @@ lbry.publish = function(params, fileListedCallback, publishedCallback, errorCall
|
||||||
// lbry.getFilesInfo() during the publish process.
|
// lbry.getFilesInfo() during the publish process.
|
||||||
|
|
||||||
// Use ES6 named arguments instead of directly passing param dict?
|
// Use ES6 named arguments instead of directly passing param dict?
|
||||||
lbry.call('publish', params, publishedCallback, (errorInfo) => {
|
lbry.call('publish', params, publishedCallback, errorCallback);
|
||||||
errorCallback({
|
|
||||||
name: fault.fault,
|
|
||||||
message: fault.faultString,
|
|
||||||
});
|
|
||||||
});
|
|
||||||
if (fileListedCallback) {
|
if (fileListedCallback) {
|
||||||
lbry.getFileInfoWhenListed(params.name, function(fileInfo) {
|
lbry.getFileInfoWhenListed(params.name, function(fileInfo) {
|
||||||
fileListedCallback(fileInfo);
|
fileListedCallback(fileInfo);
|
||||||
|
|
Loading…
Reference in a new issue