5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-26 07:06:22 +00:00
panel/app/jobs/git_pull_job.rb

13 lines
381 B
Ruby
Raw Normal View History

# frozen_string_literal: true
# Permite traer los cambios cada vez que se
# hace un push al repositorio
class GitPullJob < ApplicationJob
# @param :site [Site]
# @param :usuarie [Usuarie]
# @param :message [String]
# @return [nil]
2023-07-27 19:46:32 +00:00
def perform(site, usuarie, message)
site.repository.merge(usuarie, message) if site.repository.fetch&.positive?
end
end