arkaan 0.5.1 → 0.5.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8d5bfcbb6a55477730bc17089ae04af810db865e
4
- data.tar.gz: 478a4b33dbd76b7094db1ad123cc1557bb908201
3
+ metadata.gz: ea0c02c9402acc5c954af5f8d018444b0c6e7297
4
+ data.tar.gz: 2546c89ed4d2796550711ae13f46659317c7b7d1
5
5
  SHA512:
6
- metadata.gz: 1030fcdca64b8db9f3d829abcff756d04927fff76465c800899ec357e47148e7df126b6f13e51ba86cf7824baa46ba1559471a2350f8499bc96c9e678a309e90
7
- data.tar.gz: 0bd87c8ee10f222a47674eb55248ec31c3145dfc3e7bf0270b4e160265a3e269e1884f86215daa64a2b6d9407cca90ca5616e65cfedff088c5ebdc7a304d3488
6
+ metadata.gz: 55879e040b9346e673c2deefe95e9e762feb39c390a45411a89a2dc58546e1dafa7274c7b946f8d4bae8758f95dec6213ad136409674cbb3d39f85027d2cbb14
7
+ data.tar.gz: cbd95fd82621752bfa45c12849febf459bd149150a448ae4807c7ad4cd2d9356efe15c567921e13280b2664d405e09b4eceee70734e74bac4575aecafd1abe1a
@@ -13,6 +13,8 @@ module Arkaan
13
13
  # @return [String] the URL of the service, where the requests will be issued.
14
14
  field :url, type: String
15
15
 
16
+ field :path, type: String, default: '/'
17
+
16
18
  # @!attribute [rw] creator
17
19
  # @return [Arkaan::Account] the creator of this service.
18
20
  belongs_to :creator, class_name: 'Arkaan::Account', optional: true, inverse_of: :services
@@ -22,6 +24,8 @@ module Arkaan
22
24
  validates :url,
23
25
  presence: {message: 'service.url.blank'},
24
26
  format: {with: /\A(https?:\/\/)([\da-z\.-]+)\.([a-z\.]{2,6})([\/\w \.-]*)*\/?\z/, message: 'service.url.format', if: :url?}
27
+
28
+ validates :path, format: {with: /\A(\/:?[a-z]+)+\z/, message: 'service.path.format'}
25
29
  end
26
30
  end
27
31
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: arkaan
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vincent Courtois