mirror of
https://github.com/discourse/discourse.git
synced 2024-11-27 09:13:38 +08:00
036e27e69a
It wasn't a patch (just two helper functions that were called directly) and no longer has much to do with "Rails 4"
28 lines
728 B
Ruby
28 lines
728 B
Ruby
# frozen_string_literal: true
|
|
|
|
module FreedomPatches
|
|
module Rails4
|
|
def self.distance_of_time_in_words(*args)
|
|
Discourse.deprecate(
|
|
"FreedomPatches::Rails4.distance_of_time_in_words has moved to AgeWords.distance_of_time_in_words",
|
|
output_in_test: true,
|
|
since: "3.1.0.beta5",
|
|
drop_from: "3.2.0.beta1",
|
|
)
|
|
|
|
AgeWords.distance_of_time_in_words(*args)
|
|
end
|
|
|
|
def self.time_ago_in_words(*args)
|
|
Discourse.deprecate(
|
|
"FreedomPatches::Rails4.time_ago_in_words has moved to AgeWords.time_ago_in_words",
|
|
output_in_test: true,
|
|
since: "3.1.0.beta5",
|
|
drop_from: "3.2.0.beta1",
|
|
)
|
|
|
|
AgeWords.time_ago_in_words(*args)
|
|
end
|
|
end
|
|
end
|