AndyGura/nestjs-socket-handlers-with-ack

"msg" is a bad name for the data of the ack

Closed this issue · 2 comments

The Problem.

In your response model, you have a property called "msg", which makes for a really bad name.

  1. "msg" implies that the property is a string, but it can be everything, an object, number...
  2. "msg" is an abbreviation.
  3. "msg" is not generic enought.

How to fix?

Just rename it to "data" or something similar

If you want me to send a Pull Request to fix it, let me know

@FetzenRndy Agree, but this change is breakable. I'll leave it untouched until version 2.0.0

Done in 2.0.0