formatWelcomeMessage function

String formatWelcomeMessage(
  1. String? username
)

Format a welcome message based on username.

Implementation

String formatWelcomeMessage(String? username) {
  if (username == null || username.length > _maxUsernameLength) {
    return 'Welcome to Open Neomage';
  }
  return 'Welcome back, $username';
}