planga 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/planga.rb +8 -10
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e00081472cdf5cca52787d6a3867a4ae7b0cbc23
|
4
|
+
data.tar.gz: 1dcd4f6b70c0663339489aedef26d044dd5095f8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bae572864f863ee663a0d3ce1d21828b685cc6404ae0c80cdd523f7c33116923121eb4f461dd1d4285ff94229d6ea9d9cfe579ae106a1adf6ac6aaef43fc36b9
|
7
|
+
data.tar.gz: 0bdb061090a22dcc9d360843f64289772703c56d2619b69b41c98fde02bdcad656e3c47afef8b7210fdedd50cb591ed5eccb31022de205c91d1348fad6d4ef89
|
data/lib/planga.rb
CHANGED
@@ -39,16 +39,14 @@ class PlangaConfiguration
|
|
39
39
|
attr_accessor :public_api_id, :private_api_key, :conversation_id,
|
40
40
|
:current_user_id, :current_user_name, :container_id, :remote_host
|
41
41
|
|
42
|
-
def initialize(
|
43
|
-
|
44
|
-
|
45
|
-
@
|
46
|
-
@
|
47
|
-
@
|
48
|
-
@
|
49
|
-
@
|
50
|
-
@container_id = container_id
|
51
|
-
@remote_host = "//planga.def"
|
42
|
+
def initialize(**conf)
|
43
|
+
@public_api_id = conf[:public_api_id]
|
44
|
+
@private_api_key = conf[:private_api_key]
|
45
|
+
@conversation_id = conf[:conversation_id]
|
46
|
+
@current_user_id = conf[:current_user_id]
|
47
|
+
@current_user_name = conf[:current_user_name]
|
48
|
+
@container_id = conf[:container_id]
|
49
|
+
@remote_host = conf[:remote_host] || "//planga.def"
|
52
50
|
|
53
51
|
if not container_id
|
54
52
|
@container_id = "planga-chat-" + SecureRandom.hex
|