topfreegames/khan

View on GitHub

Showing 192 of 425 total issues

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

func (k *Khan) RetrieveClanSummary(ctx context.Context, clanID string) (*ClanSummary, error) {
    route := k.buildRetrieveClanSummaryURL(clanID)
    body, err := k.sendTo(ctx, "GET", route, nil)

    if err != nil {
Severity: Major
Found in lib/lib.go and 5 other locations - About 55 mins to fix
lib/lib.go on lines 307..318
lib/lib.go on lines 348..359
lib/lib.go on lines 393..404
lib/lib.go on lines 471..485
lib/lib.go on lines 522..532

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 125.

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

func (mr *MockKhanInterfaceMockRecorder) CreatePlayer(arg0, arg1, arg2, arg3 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreatePlayer", reflect.TypeOf((*MockKhanInterface)(nil).CreatePlayer), arg0, arg1, arg2, arg3)
}
Severity: Minor
Found in lib/mocks/khan.go and 1 other location - About 45 mins to fix
lib/mocks/khan.go on lines 287..290

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 117.

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

func (mr *MockKhanInterfaceMockRecorder) UpdatePlayer(arg0, arg1, arg2, arg3 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdatePlayer", reflect.TypeOf((*MockKhanInterface)(nil).UpdatePlayer), arg0, arg1, arg2, arg3)
}
Severity: Minor
Found in lib/mocks/khan.go and 1 other location - About 45 mins to fix
lib/mocks/khan.go on lines 107..110

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 117.

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

Identical blocks of code found in 4 locations. Consider refactoring.
Open

    for i := 0; i < b.N; i++ {
        player := fixtures.PlayerFactory.MustCreateWithOption(map[string]interface{}{
            "GameID": game.PublicID,
        }).(*models.Player)
        err = db.Insert(player)
Severity: Major
Found in bench/player_test.go and 3 other locations - About 45 mins to fix
bench/clan_test.go on lines 41..50
bench/membership_test.go on lines 44..53
bench/membership_test.go on lines 88..97

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 115.

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

Identical blocks of code found in 4 locations. Consider refactoring.
Open

    for i := 0; i < b.N; i++ {
        player := fixtures.PlayerFactory.MustCreateWithOption(map[string]interface{}{
            "GameID": game.PublicID,
        }).(*models.Player)
        err = db.Insert(player)
Severity: Major
Found in bench/clan_test.go and 3 other locations - About 45 mins to fix
bench/membership_test.go on lines 44..53
bench/membership_test.go on lines 88..97
bench/player_test.go on lines 68..77

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 115.

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

Identical blocks of code found in 4 locations. Consider refactoring.
Open

    for i := 0; i < b.N; i++ {
        player := fixtures.PlayerFactory.MustCreateWithOption(map[string]interface{}{
            "GameID": game.PublicID,
        }).(*models.Player)
        err = db.Insert(player)
Severity: Major
Found in bench/membership_test.go and 3 other locations - About 45 mins to fix
bench/clan_test.go on lines 41..50
bench/membership_test.go on lines 88..97
bench/player_test.go on lines 68..77

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 115.

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

Identical blocks of code found in 4 locations. Consider refactoring.
Open

    for i := 0; i < b.N; i++ {
        player := fixtures.PlayerFactory.MustCreateWithOption(map[string]interface{}{
            "GameID": game.PublicID,
        }).(*models.Player)
        err = db.Insert(player)
Severity: Major
Found in bench/membership_test.go and 3 other locations - About 45 mins to fix
bench/clan_test.go on lines 41..50
bench/membership_test.go on lines 44..53
bench/player_test.go on lines 68..77

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 115.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) ApplyForMembership(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ApplyForMembership", reflect.TypeOf((*MockKhanInterface)(nil).ApplyForMembership), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) CreateClan(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateClan", reflect.TypeOf((*MockKhanInterface)(nil).CreateClan), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) ApproveDenyMembershipApplication(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ApproveDenyMembershipApplication", reflect.TypeOf((*MockKhanInterface)(nil).ApproveDenyMembershipApplication), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) RetrieveClansSummary(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RetrieveClansSummary", reflect.TypeOf((*MockKhanInterface)(nil).RetrieveClansSummary), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) DeleteMembership(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteMembership", reflect.TypeOf((*MockKhanInterface)(nil).DeleteMembership), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) PromoteDemote(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PromoteDemote", reflect.TypeOf((*MockKhanInterface)(nil).PromoteDemote), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) RetrieveClanSummary(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RetrieveClanSummary", reflect.TypeOf((*MockKhanInterface)(nil).RetrieveClanSummary), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) RetrievePlayer(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RetrievePlayer", reflect.TypeOf((*MockKhanInterface)(nil).RetrievePlayer), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) ApproveDenyMembershipInvitation(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ApproveDenyMembershipInvitation", reflect.TypeOf((*MockKhanInterface)(nil).ApproveDenyMembershipInvitation), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) SearchClans(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SearchClans", reflect.TypeOf((*MockKhanInterface)(nil).SearchClans), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) LeaveClan(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "LeaveClan", reflect.TypeOf((*MockKhanInterface)(nil).LeaveClan), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) RetrieveClan(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RetrieveClan", reflect.TypeOf((*MockKhanInterface)(nil).RetrieveClan), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 137..140
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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 14 locations. Consider refactoring.
Open

func (mr *MockKhanInterfaceMockRecorder) InviteForMembership(arg0, arg1 interface{}) *gomock.Call {
    mr.mock.ctrl.T.Helper()
    return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "InviteForMembership", reflect.TypeOf((*MockKhanInterface)(nil).InviteForMembership), arg0, arg1)
}
Severity: Major
Found in lib/mocks/khan.go and 13 other locations - About 45 mins to fix
lib/mocks/khan.go on lines 47..50
lib/mocks/khan.go on lines 62..65
lib/mocks/khan.go on lines 77..80
lib/mocks/khan.go on lines 92..95
lib/mocks/khan.go on lines 122..125
lib/mocks/khan.go on lines 152..155
lib/mocks/khan.go on lines 167..170
lib/mocks/khan.go on lines 182..185
lib/mocks/khan.go on lines 197..200
lib/mocks/khan.go on lines 212..215
lib/mocks/khan.go on lines 227..230
lib/mocks/khan.go on lines 242..245
lib/mocks/khan.go on lines 272..275

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 113.

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