UNPKG

687 BJavaScriptView Raw
1/**
2 * use `$cookies` instead of `$cookieStore`
3 *
4 * In Angular 1.4, the $cookieStore service is now deprected.
5 * Please use the $cookies service instead
6 *
7 * @version 0.3.0
8 * @category deprecatedAngularFeature
9 * @sinceAngularVersion 1.x
10 */
11'use strict';
12
13module.exports = {
14 meta: {
15 schema: []
16 },
17 create: function(context) {
18 return {
19
20 MemberExpression: function(node) {
21 if (node.object && node.object.name === '$cookieStore') {
22 context.report(node, 'Since Angular 1.4, the $cookieStore service is deprecated. Please use now the $cookies service.', {});
23 }
24 }
25 };
26 }
27};