2018-11-29 11:08:14 -05:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2019-03-28 09:17:42 -04:00
|
|
|
class ProjectRepository < ApplicationRecord
|
2018-11-29 11:08:14 -05:00
|
|
|
include Shardable
|
|
|
|
|
|
|
|
belongs_to :project, inverse_of: :project_repository
|
|
|
|
|
|
|
|
class << self
|
|
|
|
def find_project(disk_path)
|
|
|
|
find_by(disk_path: disk_path)&.project
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|