@ascua/metrics 0.4.6 → 0.6.0

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.
@@ -1,9 +1,9 @@
1
1
  import Service from '@ember/service';
2
- import { inject } from '@ember/service';
2
+ import { service } from '@ember/service';
3
3
 
4
4
  export default class extends Service {
5
5
 
6
- @inject router;
6
+ @service router;
7
7
 
8
8
  platforms = [];
9
9
 
@@ -21,53 +21,53 @@ export default class extends Service {
21
21
 
22
22
  clear(n) {
23
23
  switch (arguments.length) {
24
- case 1:
25
- if (this[n]) {
26
- return this[n].clear();
27
- }
28
- case 0:
29
- return this.platforms.forEach(m => {
30
- m.clear();
31
- });
24
+ case 1:
25
+ if (this[n]) {
26
+ return this[n].clear();
27
+ }
28
+ case 0:
29
+ return this.platforms.forEach(m => {
30
+ m.clear();
31
+ });
32
32
  }
33
33
  }
34
34
 
35
35
  identify(n, id, data) {
36
36
  switch (arguments.length) {
37
- case 3:
38
- if (this[n]) {
39
- return this[n].identify(id, data);
40
- }
41
- case 2:
42
- return this.platforms.forEach(m => {
43
- m.identify(...arguments);
44
- });
37
+ case 3:
38
+ if (this[n]) {
39
+ return this[n].identify(id, data);
40
+ }
41
+ case 2:
42
+ return this.platforms.forEach(m => {
43
+ m.identify(...arguments);
44
+ });
45
45
  }
46
46
  }
47
47
 
48
48
  trackPage(n, data) {
49
49
  switch (arguments.length) {
50
- case 2:
51
- if (this[n]) {
52
- return this[n].trackPage(data);
53
- }
54
- case 1:
55
- return this.platforms.forEach(m => {
56
- m.trackPage(...arguments);
57
- });
50
+ case 2:
51
+ if (this[n]) {
52
+ return this[n].trackPage(data);
53
+ }
54
+ case 1:
55
+ return this.platforms.forEach(m => {
56
+ m.trackPage(...arguments);
57
+ });
58
58
  }
59
59
  }
60
60
 
61
61
  trackEvent(n, name, data) {
62
62
  switch (arguments.length) {
63
- case 3:
64
- if (this[n]) {
65
- return this[n].trackEvent(name, data);
66
- }
67
- case 2:
68
- return this.platforms.forEach(m => {
69
- m.trackEvent(...arguments);
70
- });
63
+ case 3:
64
+ if (this[n]) {
65
+ return this[n].trackEvent(name, data);
66
+ }
67
+ case 2:
68
+ return this.platforms.forEach(m => {
69
+ m.trackEvent(...arguments);
70
+ });
71
71
  }
72
72
  }
73
73
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ascua/metrics",
3
- "version": "0.4.6",
3
+ "version": "0.6.0",
4
4
  "description": "Small description for @ascua/metrics goes here",
5
5
  "keywords": [
6
6
  "ember-addon"
@@ -25,5 +25,5 @@
25
25
  "publishConfig": {
26
26
  "access": "public"
27
27
  },
28
- "gitHead": "7d208a6c14a4dda0d8cd39a9ec8640892de67c80"
28
+ "gitHead": "56b63607322165599c91049cbb91e5241ca8234c"
29
29
  }