Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create Rake tasks for deleting user details
This is the glue required to run the use cases. The Rubocop ignore syntax is due to this. rubocop/rubocop#4222
- Loading branch information
1 parent
5c59186
commit 7d406d6
Showing
4 changed files
with
17 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
Lint/AmbiguousBlockAssociation: | ||
Exclude: | ||
- "spec/**/*" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
require './lib/loader' | ||
|
||
require './tasks/publish_statistics' | ||
require './tasks/gdpr/user_deletion' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
require 'logger' | ||
logger = Logger.new(STDOUT) | ||
|
||
task :delete_users do | ||
user_details_gateway = Gdpr::Gateway::Userdetails.new | ||
|
||
Gdpr::UseCase::DeleteUsers.new(user_details_gateway: user_details_gateway).execute | ||
Gdpr::UseCase::ObfusticateSponsors.new(user_details_gateway: user_details_gateway).execute | ||
|
||
logger.info('Daily User Cleanup Ran') | ||
end |