Skip to content

Commit 582a86c

Browse files
committed
fix syntax/lint issue
1 parent 0ef2405 commit 582a86c

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/store.deep.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,12 @@
1111
*
1212
* Status: ALPHA - currently only supports get
1313
*/
14-
; (function (_) {
14+
;(function(_) {
1515

1616
// save original core accessor
1717
var _get = _.get;
1818
// replace with enhanced version
19-
_.get = function (area, key, kid) {
19+
_.get = function(area, key, kid) {
2020
var s = _get(area, key);
2121
if (s == null) {
2222
var parts = _.split(key);
@@ -31,20 +31,20 @@
3131
val = _.resolvePath(val, kid);
3232
s = _.stringify(val);
3333
} catch (e) {
34-
console.error("Error accessing nested property:", e);
34+
window.console.error("Error accessing nested property:", e);
3535
return null;
3636
}
3737
}
3838
return s;
3939
};
4040

4141
// Helper function to resolve nested paths safely
42-
_.resolvePath = function (obj, path) {
43-
return path.split('.').reduce((acc, key) => acc && acc[key], obj);
42+
_.resolvePath = function(obj, path) {
43+
return path.split('.').reduce(function(acc, key) { return acc && acc[key]; }, obj);
4444
};
4545

4646
// expose internals on the underscore to allow extensibility
47-
_.split = function (key) {
47+
_.split = function(key) {
4848
var dot = key.lastIndexOf('.');
4949
if (dot > 0) {
5050
var kid = key.substring(dot + 1, key.length);

0 commit comments

Comments
 (0)