Spaces:
Runtime error
Runtime error
Update src/lib/tw-project-meta-fetcher-hoc.jsx
Browse files
src/lib/tw-project-meta-fetcher-hoc.jsx
CHANGED
|
@@ -59,7 +59,8 @@ const TWProjectMetaFetcherHOC = function (WrappedComponent) {
|
|
| 59 |
}
|
| 60 |
componentDidUpdate() {
|
| 61 |
// project title resetting is handled in titled-hoc.jsx
|
| 62 |
-
this.props.vm.runtime.renderer
|
|
|
|
| 63 |
this.props.onSetAuthor('', '');
|
| 64 |
this.props.onSetDescription('', '');
|
| 65 |
this.props.onSetRemixedProjectInfo(false, '', '');
|
|
@@ -106,7 +107,7 @@ const TWProjectMetaFetcherHOC = function (WrappedComponent) {
|
|
| 106 |
rawData.public === true
|
| 107 |
) {
|
| 108 |
this.props.onSetExtraProjectInfo(
|
| 109 |
-
rawData.
|
| 110 |
String(rawData.remix) !== '0',
|
| 111 |
String(rawData.remix),
|
| 112 |
false,
|
|
@@ -139,7 +140,8 @@ const TWProjectMetaFetcherHOC = function (WrappedComponent) {
|
|
| 139 |
setIndexable(true);
|
| 140 |
})
|
| 141 |
.catch(err => {
|
| 142 |
-
this.props.vm.runtime.renderer
|
|
|
|
| 143 |
setIndexable(false);
|
| 144 |
if (`${err}`.includes('unshared')) {
|
| 145 |
this.props.onSetDescription('unshared', 'unshared');
|
|
@@ -215,4 +217,4 @@ const TWProjectMetaFetcherHOC = function (WrappedComponent) {
|
|
| 215 |
|
| 216 |
export {
|
| 217 |
TWProjectMetaFetcherHOC as default
|
| 218 |
-
};
|
|
|
|
| 59 |
}
|
| 60 |
componentDidUpdate() {
|
| 61 |
// project title resetting is handled in titled-hoc.jsx
|
| 62 |
+
if (this.props.vm.runtime.renderer?.setPrivateSkinAccess)
|
| 63 |
+
this.props.vm.runtime.renderer.setPrivateSkinAccess(true);
|
| 64 |
this.props.onSetAuthor('', '');
|
| 65 |
this.props.onSetDescription('', '');
|
| 66 |
this.props.onSetRemixedProjectInfo(false, '', '');
|
|
|
|
| 107 |
rawData.public === true
|
| 108 |
) {
|
| 109 |
this.props.onSetExtraProjectInfo(
|
| 110 |
+
!rawData.softRejected,
|
| 111 |
String(rawData.remix) !== '0',
|
| 112 |
String(rawData.remix),
|
| 113 |
false,
|
|
|
|
| 140 |
setIndexable(true);
|
| 141 |
})
|
| 142 |
.catch(err => {
|
| 143 |
+
if (this.props.vm.runtime.renderer?.setPrivateSkinAccess)
|
| 144 |
+
this.props.vm.runtime.renderer.setPrivateSkinAccess(false);
|
| 145 |
setIndexable(false);
|
| 146 |
if (`${err}`.includes('unshared')) {
|
| 147 |
this.props.onSetDescription('unshared', 'unshared');
|
|
|
|
| 217 |
|
| 218 |
export {
|
| 219 |
TWProjectMetaFetcherHOC as default
|
| 220 |
+
};
|