Skip to content

Commit

Permalink
[webui][api] Always set the channel binary name when creating binary …
Browse files Browse the repository at this point in the history
…data

The SQL query we use to create the channel_binary table is setting a NOT NULL
constraint. Thus the name would always be set.
  • Loading branch information
bgeuken committed Aug 18, 2015
1 parent e67794c commit 871a6fb
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/api/app/models/channel_binary.rb
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,10 @@ def create_xml(options = {})
package: channel.package.name
}
builder.channel(attributes) do |c|
p={}
p = { name: name }
p[:package] = package if package
p[:name] = name if name
p[:binaryarch] = binaryarch if binaryarch
p[:supportstatus] = supportstatus if supportstatus
next unless p.length > 0
c.binary(p)

# report target repository and products using it.
Expand Down

0 comments on commit 871a6fb

Please sign in to comment.