mirror of
https://github.com/discourse/discourse.git
synced 2024-11-24 15:49:55 +08:00
c4b5455c21
will likely whitelist more crawlers in the future.
6 lines
127 B
Ruby
6 lines
127 B
Ruby
module CrawlerDetection
|
|
def self.crawler?(user_agent)
|
|
!/Googlebot|Mediapartners|AdsBot/.match(user_agent).nil?
|
|
end
|
|
end
|