iAuditor 0.1.2.17 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 510dcd17ccf091bb0f058a272ba8ae823eb1d450
4
- data.tar.gz: 1f3f5ae3ce11bd9c340ac496bfa035b3daa3986b
3
+ metadata.gz: 9727b8629ce062fc6aac6e91e2d27da3b8e131d9
4
+ data.tar.gz: 7fb7a4c6a352f5da80f7d54d7df76a186693f259
5
5
  SHA512:
6
- metadata.gz: cf7d221cc25e7769a82c424fee927bb32f71c825070b8e7df5f9614926fa862ab17a629ed891b1c5fbab3b6bd19be8c2a772b3852a55c42ea678e0eaa9099ca6
7
- data.tar.gz: 506b13f48e05739d9f0502bae38a5fb253c7b40a5bca3310c072f768dba5003ca8ac0b92c4b859363f37a56a19265a817a08bbd041f15859e234256ffeb9d896
6
+ metadata.gz: 758cf70070f32e1ef18738c51cc469c629cc3cdfda1ae8323b2ee21373ff739c3c404dabeabd23c57eeebdeab8d4c58cc56744bd4c8e08f81a636cb3c7287570
7
+ data.tar.gz: 7ec412ed80c32fdfd341c01ec8e00efda943f17d9f81318e4960cca02bcd30fe4bcbf4fb8b17a3fea9767b28a8c844da0341e123bcbecb2dbb066c484189c8f8
@@ -3,10 +3,9 @@ module IAuditor
3
3
  class Audit
4
4
  include BaseModules::Methods
5
5
 
6
-
7
6
  # Retrieving all audits with the given search criteria
8
7
  def search(options={})
9
- @options.merge!(query: options) if options.present?
8
+ @options.merge!(query: options) if options.any?
10
9
  @audits = self.class.get("/audits/search", @options)
11
10
  @audits.parsed_response
12
11
  end
@@ -1,9 +1,9 @@
1
+ require 'pry'
1
2
 
2
3
  class BaseModules
3
4
  module Methods
4
5
 
5
6
  def initialize(token)
6
-
7
7
  @options = token.is_a?(String) ? {
8
8
  headers: {
9
9
  "Content-Type": "application/json",
@@ -19,7 +19,8 @@ class BaseModules
19
19
 
20
20
 
21
21
  def self.included(base)
22
- base.send :include, "HTTParty".constantize
22
+ # "HTTParty".constantize does not support in plain ruby -- If you have ActiveSupport loaded (e.g. in Rails) you can use
23
+ base.send :include, Object.const_get("HTTParty")
23
24
  base.send(:base_uri, "https://api.safetyculture.io")
24
25
  end
25
26
 
@@ -1,3 +1,3 @@
1
1
  module IAuditor
2
- VERSION = "0.1.2.17"
2
+ VERSION = "0.1.3"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: iAuditor
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2.17
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Wetteroth
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2018-04-24 00:00:00.000000000 Z
12
+ date: 2018-06-06 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler