README.md in decidim-cdtb-0.1.3 vs README.md in decidim-cdtb-0.1.4

- old
+ new

@@ -74,9 +74,31 @@ `bin/rake cdtb:s3_to_local:set_local_service_on_blobs` 4. Clean the cache: `bin/rake cache:clear` 5. Restart the Rails server +### Detect spam + +To detect spam in Decidim. + +#### Detect spam users +Detects users susceptible of being spammers. It can run on all organizations or be scoped to a single organization by passing the organization ID as the rake task parameter. + +This rake task export a .csv with a list of all the searched users. A column indicates if each user is suspicious of being a spammer or not. +The columns in the CSV are: "ID, "Is suspicious?", "Name", "Email", "Nickname", "Personal URL", "About" + +Examples: +`bin/rake cdtb:spam:users[org_id]` --> find users in organization with an id. +`bin/rake cdtb:spam:users` --> find all users in all organizations. + +To set custom words in the rake, you can override it with an initalizer: + +``` +Decidim::Cdtb.configure do |config| + config.spam_words = ENV["CDTB_SPAM_WORDS"]&.split(",") +end +``` + ### Upgrades: #### Upgrade modules Upgrades the gems with engines in them. All, Decidim modules and standard Rails engines.