Skip to content

Commit

Permalink
[api] also accept verifymd5 for lastsuccess calls
Browse files Browse the repository at this point in the history
  • Loading branch information
coolo authored and adrianschroeter committed Jul 7, 2014
1 parent 5f307d0 commit 5daca61
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/api/app/models/package_build_status.rb
Expand Up @@ -85,10 +85,9 @@ def check_repo_arch_status(srep, arch)
@result[srep['name']][arch][:missing] = missingdeps.uniq
end

def current_srcmd5
cdir = Directory.hashed(project: @pkg.project.name,
package: @pkg.name, view: :info)
cdir['srcmd5']
def current_dir
Directory.hashed(project: @pkg.project.name,
package: @pkg.name, view: :info)
end

def gather_current_buildcode(srep, arch)
Expand All @@ -114,7 +113,8 @@ def gather_current_buildcode(srep, arch)
end
# if it's currently succeeded but !@everbuilt, it's different sources
if currentcode == 'succeeded'
if @srcmd5 == current_srcmd5
dir = current_dir
if @srcmd5 == dir['srcmd5'] || @srcmd5 == dir['verifymd5']
@buildcode='building' # guesssing
else
@buildcode='outdated'
Expand Down Expand Up @@ -189,6 +189,6 @@ def gather_md5sums
package: @pkg.name,
rev: @srcmd5,
view: :info)
@verifymd5 = cdir['verifymd5']
@verifymd5 = cdir['verifymd5'] || @srcmd5
end
end

0 comments on commit 5daca61

Please sign in to comment.