Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refs #19588 - Allow passing header to csv responder #4578

Merged
merged 1 commit into from
Jun 12, 2017

Conversation

tbrisker
Copy link
Member

@tbrisker tbrisker commented Jun 8, 2017

No description provided.

@@ -1,7 +1,8 @@
require 'csv'

module CsvExporter
def self.export(resources, columns, header = default_header(columns))
def self.export(resources, columns, header = nil)
header ||= default_header(columns)
Copy link
Member Author

@tbrisker tbrisker Jun 11, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can't use default value here because the csv responder may pass a nil which will cause the default value to be ignored.

@dLobatog dLobatog merged commit 2758227 into theforeman:develop Jun 12, 2017
@dLobatog
Copy link
Member

Thanks @tbrisker !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants