Skip to content
Snippets Groups Projects
Unverified Commit 0d65612e authored by Sébastien Gaya's avatar Sébastien Gaya Committed by GitHub
Browse files

fix memoize on class method (#1787)

parent 2f4012e5
No related branches found
No related tags found
No related merge requests found
class Osuny::ThemeInfo
def self.get_current_version
@last_version ||= client.releases(ENV["GITHUB_WEBSITE_THEME_REPOSITORY"]).first[:tag_name]
client.releases(ENV["GITHUB_WEBSITE_THEME_REPOSITORY"]).first[:tag_name]
end
def self.get_current_sha
@current_theme_sha ||= client.branch(ENV["GITHUB_WEBSITE_THEME_REPOSITORY"], ENV["GITHUB_WEBSITE_THEME_BRANCH"])[:commit][:sha]
client.branch(ENV["GITHUB_WEBSITE_THEME_REPOSITORY"], ENV["GITHUB_WEBSITE_THEME_BRANCH"])[:commit][:sha]
end
private
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment