Skip to content

Missed postfix "ClientServer" (CommonModuleNameClientServer)

Type Scope Severity Activated
by default
Minutes
to fix
Tags
Code smell BSL Major Yes 5 standard
badpractice
unpredictable

Description

To avoid code duplication, it is recommended to create client-server common modules with methods whose contents are the same on the server and on the client. These modules have signs:

  • Client (Managed application)
  • Server (ServerCall is disabled)
  • Client (Ordinary application)
  • External connection

Common modules of this type are named with the "ClientServer" (rus. "КлиентСервер").

Examples

FilesClientServer, CommonClientServer, UsersClientServer

Sources

Standard: Rules for creating common modules (RU)

Snippets

Diagnostic ignorance in code

// BSLLS:CommonModuleNameClientServer-off
// BSLLS:CommonModuleNameClientServer-on

Parameter for config

"CommonModuleNameClientServer": false