Method: JSS::User#remove_site

Defined in:
lib/jss/api_object/user.rb

#remove_site(site) ⇒ void

This method returns an undefined value.

Remove this user from a site

Parameters:

  • site (String)

    the name of the site



246
247
248
249
250
# File 'lib/jss/api_object/user.rb', line 246

def remove_site (site)
  return nil unless @sites.map{|s| s[:name]}.include? site
  @sites.reject!{|s| s[:name] == site}
  @need_to_update = true
end