Project

General

Profile

« Previous | Next » 

Revision af19cdc5

Added by Marc Dequènes almost 15 years ago

  • ID af19cdc59052827405ad1a56e347687caba69f41

[fix] code cleanup and a few fixes

View differences:

lib/ldap_shadows/display_utils.rb
module Display
def self.display_fields(attr_data, options = {})
attr_data.each_pair do |key, val|
next if attr_data[:expert] and options[:expert]
next if val[:expert] and not options[:expert]
field_name = Translator.translate_field_name(key)
......
end
end
def self.display_item_list(title, item_list)
def self.display_item_list(title, item_list, options)
puts "=== #{title} (#{item_list.size}) ==="
item_list.each do |item|
str = item.human_name
str += " [#{item.name}]" if $program_options[:handles]
str += " [#{item.name}]" if options[:handles]
str += ": #{item.description}" unless item.description.empty?
puts str
end

Also available in: Unified diff