Skip to content

Commit c4cef98

Browse files
committed
COMPASS-137: Fix eslint errors
1 parent b1c0b10 commit c4cef98

File tree

2 files changed

+13
-8
lines changed

2 files changed

+13
-8
lines changed

src/internal-packages/collection-stats/lib/component/index.jsx

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,12 @@ const AVG_SIZE = 'avg. size';
4141
* The default stats state.
4242
*/
4343
const DEFAULT_STATS = {
44-
documentCount: 'N/A',
45-
totalDocumentSize: 'N/A',
46-
avgDocumentSize: 'N/A',
47-
indexCount: 'N/A',
48-
totalIndexSize: 'N/A',
49-
avgIndexSize: 'N/A'
44+
documentCount: INVALID,
45+
totalDocumentSize: INVALID,
46+
avgDocumentSize: INVALID,
47+
indexCount: INVALID,
48+
totalIndexSize: INVALID,
49+
avgIndexSize: INVALID
5050
};
5151

5252
/**
@@ -56,6 +56,8 @@ class CollectionStats extends React.Component {
5656

5757
/**
5858
* Instantiate the component.
59+
*
60+
* @param {Object} props - The properties.
5961
*/
6062
constructor(props) {
6163
super(props);
@@ -78,6 +80,8 @@ class CollectionStats extends React.Component {
7880

7981
/**
8082
* Handle the loading of the collection stats.
83+
*
84+
* @param {Object} stats - The stats.
8185
*/
8286
handleStatsLoad(stats) {
8387
this.setState(stats || DEFAULT_STATS);

src/internal-packages/collection-stats/lib/store/index.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ const CollectionStatsStore = Reflux.createStore({
2525

2626
/**
2727
* Load the collection stats.
28+
*
29+
* @param {String} ns - The namespace.
2830
*/
2931
loadCollectionStats: function(ns) {
3032
if (toNS(ns || '').collection) {
@@ -41,14 +43,13 @@ const CollectionStatsStore = Reflux.createStore({
4143
},
4244

4345
_parseCollectionDetails(result) {
44-
console.log(result);
4546
return {
4647
documentCount: this._format(result.document_count),
4748
totalDocumentSize: this._format(result.document_size, 'b'),
4849
avgDocumentSize: this._format(this._avg(result.document_size, result.document_count), 'b'),
4950
indexCount: this._format(result.index_count),
5051
totalIndexSize: this._format(result.index_size, 'b'),
51-
avgIndexSize: this._format(this._avg(result.index_size, result.index_count), 'b'),
52+
avgIndexSize: this._format(this._avg(result.index_size, result.index_count), 'b')
5253
};
5354
},
5455

0 commit comments

Comments
 (0)