5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-06-29 10:16:08 +00:00

deprecar un atributo que nunca usamos

This commit is contained in:
f 2021-04-16 10:36:38 -03:00
parent 8fc054a735
commit 6e9b09e19b

View file

@ -6,13 +6,12 @@ class Site
# que un sitio tiene un solo origen, que siempre se trabaja con la # que un sitio tiene un solo origen, que siempre se trabaja con la
# rama master, etc. # rama master, etc.
class Repository class Repository
attr_reader :rugged, :changes, :path attr_reader :rugged, :path
# @param [String] la ruta del repositorio # @param [String] la ruta del repositorio
def initialize(path) def initialize(path)
@path = path @path = path
@rugged = Rugged::Repository.new(path) @rugged = Rugged::Repository.new(path)
@changes = 0
end end
# Obtiene la rama por defecto a partir de la referencia actual # Obtiene la rama por defecto a partir de la referencia actual
@ -46,7 +45,7 @@ class Site
# @return [Integer] # @return [Integer]
def fetch def fetch
if origin.check_connection :fetch if origin.check_connection :fetch
@changes = rugged.fetch(origin)[:received_objects] rugged.fetch(origin)[:received_objects]
else else
0 0
end end