CHANGES.md in ruby-jss-1.0.4 vs CHANGES.md in ruby-jss-1.1.0b1

- old
+ new

@@ -4,9 +4,35 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). ## \[Unreleased] ### Added +- MobileDeviceExtensionAttribute now has a `.history` class method matching that of ComputerExtensionAttribute. Requires direct MySQL database access. Thanks @aurica! +- JSS::AmbiguousError exception class +- More caching of API data to improve general speed + - The hashes created by `APIObject.map_all_ids_to(blah)` + - ExtensionAttribute definitions when used by extendable classes +- Implemented Ruby2.4's `String#casecmp?` in older Rubies +- APIObject.fetch can take the search term `:random` and you'll get a randomly selected object. Example: `a_random_computer = JSS::Computer.fetch :random` +- Keys of the hash returned by `Computer#hardware` are now available as instance methods on Computer objects. So instead of `a_computer.hardware[:total_ram]` you can also do `a_computer.total_ram` + + +### Fixed +- Can't Modify Frozen Hash error when instantiating JSS::Scopbable::Scope. Thanks to @shahn for reporting this one. +- MobileDeviceExtensionAttribute now handles empty `as_of` timestamp. Thanks @aurica! +- A couple of typos. Thanks to @cybertunnel for finding one. +- A bug when parsing the `server_path` parameter to `API::Connection.new` + +### Changed +- Monkey Patches are being moved to a better, more traceable technique, see https://www.justinweiss.com/articles/3-ways-to-monkey-patch-without-making-a-mess/ +- MobileDevices and Computers now raise JSS::AmbiguousError when being fetched by explicitly by name, e.g. `JSS::Computer.fetch name: 'foo'` and that name is not unique in the JSS. Previously, you'd get an object back, but no guarantee as to which one it was. You'll still get an undefined object if you use a bare searchterm, e.g. `JSS::Computer.fetch 'foo'` +- Documentation for subclassing APIObject is updated & expanded. See the comments above the class definition in api_object.rb +- `APIObject.valid_id` is now case-insensitive +- Removed deprecated VALID_DATA_KEYS constants from APIObject subclasses +- Various changes in APIObject and its subclasses to try making `.fetch` and other lookup-methods faster. + +## \[1.0.4] - 2019-05-06 +### Added - JSS::Group (and its subclasses) now have a `change_membership` class and instance method for static groups. - The class method allows adding and removing members without fetching an instance of the group. - The instance method adds and/or removes members immediately, without needing to call #update or #save - LDAPServer.server_for_user and .server_for_group class methods, return the id of the first LDAP server containing the given user or group