@@ -109,16 +109,6 @@ class TwitterHook {
109109 } catch ( e ) {
110110 this . main . xlog ( 'error' , 'Failed to add account change event listener.' , e ) ;
111111 }
112-
113- // // Listen on route change Event
114- // try {
115- // this.main.xlog('info', 'Adding route change event listener.');
116- // window.removeEventListener('locationchange', () => this.mountSyncOldTweets()); // Remove old (if any)
117- // window.addEventListener('locationchange', () => this.mountSyncOldTweets()); // Add new
118- // } catch (e) {
119- // this.main.xlog('error', 'Failed to add route change event listener.', e);
120- // }
121- // this.mountSyncOldTweets(); // Init Run
122112 }
123113
124114 private async sync ( note : NoteInput , attachmentUrls ?: string [ ] ) {
@@ -247,14 +237,6 @@ class TwitterHook {
247237 if ( settings . syncing !== false && settings . address ) {
248238 if ( settings . address . toLowerCase ( ) !== this . main . address ?. toLowerCase ( ) ) {
249239 newStatus = 'Address changed.' ;
250- // this.main.xlog('info', 'Old address: ', settings.address);
251- // this.main.xlog('info', 'Now address: ', this.main.address);
252- // } else if (unidata) { // Disabled for unidata.utils.contract is undefined
253- // settings.syncing = true;
254- // const balance = (await unidata.utils.contract.getBalance(this.main.address)).data;
255- // if (parseInt(balance) < 0.0005 * Math.pow(10, 18)) {
256- // newStatus = 'Balance might not enough.';
257- // }
258240 }
259241 if ( newStatus !== '' ) {
260242 this . main . xlog ( 'warn' , newStatus ) ;
@@ -319,8 +301,6 @@ class TwitterHook {
319301 }
320302 } ,
321303 postNote : async ( ) => {
322- let newNoteID = '' ;
323-
324304 const note = {
325305 tags : [ 'CrossSync' , 'Twitter' ] ,
326306 authors : [ `csb://account:${ username } @twitter` ] ,
0 commit comments