Open tshemsedinov opened 3 months ago
Thank you for your attention @tshemsedinov. An expression with two operations is not long. It's a common approach to assigning a default value when a parameter is not provided. Our team prefers this approach for default values instead of re-assignments with let declarations. In other situations, when things are more complicated than substituting default values, we do not use such expressions with await inside.
It is much better to use intermediate variables instead of such a long expressions, even more... with await in the middle
https://github.com/diia-open-source/be-user-service/blob/b45a0e2db354df110a99254516a414aaac43be61/src/services/diiaId.ts#L112-L113