Showing 21 of 31 total issues

Similar blocks of code found in 2 locations. Consider refactoring.
Open

RiakPBC.prototype.getIndex = function (params, callback) {

    params.stream = true;

    return this._makeRequest({
Severity: Major
Found in index.js and 1 other location - About 1 hr to fix
index.js on lines 105..115

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 65.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

RiakPBC.prototype.getKeys = function (params, callback) {

    params.stream = true;

    return this._makeRequest({
Severity: Major
Found in index.js and 1 other location - About 1 hr to fix
index.js on lines 204..214

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 65.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.getBuckets = function (params, callback) {

    return this._makeRequest({
        type: 'RpbListBucketsReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.get = function (params, callback) {

    return this._makeRequest({
        type: 'RpbGetReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.resetBucket = function (params, callback) {

    return this._makeRequest({
        type: 'RpbResetBucketReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.getSearchSchema = function (params, callback) {

    return this._makeRequest({
        type: 'RpbYokozunaSchemaGetReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.setBucket = function (params, callback) {

    return this._makeRequest({
        type: 'RpbSetBucketReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.getSearchIndex = function (params, callback) {

    return this._makeRequest({
        type: 'RpbYokozunaIndexGetReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.putSearchIndex = function (params, callback) {

    return this._makeRequest({
        type: 'RpbYokozunaIndexPutReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.putCrdt = function (params, callback) {

    return this._makeRequest({
        type: 'DtUpdateReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.putSearchSchema = function (params, callback) {

    return this._makeRequest({
        type: 'RpbYokozunaSchemaPutReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.del = function (params, callback) {

    return this._makeRequest({
        type: 'RpbDelReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.search = function (params, callback) {

    return this._makeRequest({
        type: 'RpbSearchQueryReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.getBucketType = function (params, callback) {

    return this._makeRequest({
        type: 'RpbGetBucketTypeReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.setBucketType = function (params, callback) {

    return this._makeRequest({
        type: 'RpbSetBucketTypeReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.getBucket = function (params, callback) {

    return this._makeRequest({
        type: 'RpbGetBucketReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.delSearchIndex = function (params, callback) {

    return this._makeRequest({
        type: 'RpbYokozunaIndexDeleteReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.put = function (params, callback) {

    return this._makeRequest({
        type: 'RpbPutReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 261..268
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 17 locations. Consider refactoring.
Open

RiakPBC.prototype.getCrdt = function (params, callback) {

    return this._makeRequest({
        type: 'DtFetchReq',
        params: params,
Severity: Major
Found in index.js and 16 other locations - About 40 mins to fix
index.js on lines 96..103
index.js on lines 117..124
index.js on lines 126..133
index.js on lines 135..142
index.js on lines 144..151
index.js on lines 153..160
index.js on lines 162..169
index.js on lines 216..223
index.js on lines 243..250
index.js on lines 252..259
index.js on lines 270..277
index.js on lines 279..286
index.js on lines 288..295
index.js on lines 297..304
index.js on lines 306..313
index.js on lines 315..322

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 49.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

RiakPBC.prototype.getServerInfo = function (callback) {

    return this._makeRequest({
        type: 'RpbGetServerInfoReq',
        params: null,
Severity: Minor
Found in index.js and 1 other location - About 40 mins to fix
index.js on lines 225..232

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 48.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Severity
Category
Status
Source
Language