@@ -8,7 +8,7 @@ import log from './log';
88const { API_HOST } = require ( './brand' ) ;
99
1010import { setProjectTitle } from '../reducers/project-title' ;
11- import { setAuthor , setDescription , setUsername } from '../reducers/tw' ;
11+ import { setAuthor , setDescription } from '../reducers/tw' ;
1212
1313import storage from './storage' ;
1414
@@ -88,11 +88,7 @@ const TWProjectMetaFetcherHOC = function (WrappedComponent) {
8888 if ( title ) {
8989 this . props . onSetProjectTitle ( title ) ;
9090 }
91- const username = data . username ;
92- if ( username ) {
93- this . props . onSetUsername ( username ) ;
94- this . setState ( { canUseCloud : true } ) ;
95- }
91+
9692 const authorName = data . author . username ;
9793 const authorThumbnail = data . author . PFP ;
9894 this . props . onSetAuthor ( authorName , authorThumbnail ) ;
@@ -103,7 +99,8 @@ const TWProjectMetaFetcherHOC = function (WrappedComponent) {
10399 }
104100
105101 this . setState ( { canSave : data . canSave === 'true' } ) ;
106- // this.setState({canEditTitle: true}); // if you can save, you can edit title (it doesn't work the prop isn't passed down)
102+ // if you can save, you can edit title (it doesn't work the prop isn't passed down)
103+ // this.setState({canEditTitle: true});
107104 this . setState ( { canRemix : data . canRemix === 'true' } ) ;
108105 storage . setCloudOTT ( data ?. cloudDataOTT ) ;
109106 storage . setCustomAchievements ( data ?. customAchievements ) ;
@@ -129,7 +126,6 @@ const TWProjectMetaFetcherHOC = function (WrappedComponent) {
129126 onSetAuthor,
130127 onSetDescription,
131128 onSetProjectTitle,
132- onSetUsername,
133129 /* eslint-enable no-unused-vars */
134130 ...props
135131 } = this . props ;
@@ -147,8 +143,7 @@ const TWProjectMetaFetcherHOC = function (WrappedComponent) {
147143 reduxProjectId : PropTypes . string ,
148144 onSetAuthor : PropTypes . func ,
149145 onSetDescription : PropTypes . func ,
150- onSetProjectTitle : PropTypes . func ,
151- onSetUsername : PropTypes . func
146+ onSetProjectTitle : PropTypes . func
152147 } ;
153148 const mapStateToProps = state => ( {
154149 reduxProjectId : state . scratchGui . projectState . projectId
@@ -162,8 +157,7 @@ const TWProjectMetaFetcherHOC = function (WrappedComponent) {
162157 instructions,
163158 credits
164159 } ) ) ,
165- onSetProjectTitle : title => dispatch ( setProjectTitle ( title ) ) ,
166- onSetUsername : username => dispatch ( setUsername ( username ) )
160+ onSetProjectTitle : title => dispatch ( setProjectTitle ( title ) )
167161 } ) ;
168162 return connect (
169163 mapStateToProps ,
0 commit comments