Skip to content
This repository has been archived by the owner on Jan 24, 2021. It is now read-only.

Commit

Permalink
Improve anonymization script
Browse files Browse the repository at this point in the history
  • Loading branch information
iGitScor committed Mar 25, 2019
1 parent 155a91c commit aff7bd8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 11 deletions.
7 changes: 3 additions & 4 deletions source/features/anonymize-tweets.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
export default function () {
$('.FullNameGroup .fullname').text('Jane Doe');
$('.js-retweet-text b').text('Jane Doe');
$('.UserBadges').hide();
$('.username').hide();
const anonymousAccount = Math.random() >= 0.5 ? 'Jane Doe' : 'John Doe';
$('.FullNameGroup .fullname, .js-retweet-text b').text(anonymousAccount);
$('.UserBadges, .username').hide();
$('.avatar').attr('src', 'https://abs.twimg.com/sticky/default_profile_images/default_profile_4_bigger.png');
}
14 changes: 7 additions & 7 deletions source/features/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,13 @@ export const features = {
},

/* TIMELINE */
anonymizeTweets: {
id: 'feature-anonymous-tweets',
category: 'timeline',
label: 'Transform your timeline in Jane Doe tweets timeline',
enabledByDefault: false,
fn: require('./anonymize-tweets').default
},
autoLoadNewTweets: {
id: 'feature-auto-load-new-tweets',
category: 'timeline',
Expand Down Expand Up @@ -184,13 +191,6 @@ export const features = {
fn: require('./inline-instagram-photos').default,
hidden: true
},
janeDoeTweets: {
id: 'feature-anonymous-tweets',
category: 'timeline',
label: 'Transform your timeline in Jane Doe tweets timeline',
enabledByDefault: false,
fn: require('./anonymize-tweets').default
},
mentionHighlight: {
id: 'feature-mentions-highlight',
category: 'timeline',
Expand Down

0 comments on commit aff7bd8

Please sign in to comment.