From f0a551e1aacc7a7315521da4ff02609b8088c678 Mon Sep 17 00:00:00 2001 From: Igor Zhukov Date: Fri, 12 Jan 2018 20:16:36 +0400 Subject: [PATCH] Allow to create group with 1 participant --- app/js/controllers.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/app/js/controllers.js b/app/js/controllers.js index 8e35b1bf..c77bd8ae 100644 --- a/app/js/controllers.js +++ b/app/js/controllers.js @@ -567,9 +567,8 @@ angular.module('myApp.controllers', ['myApp.i18n']) $scope.openGroup = function () { ContactsSelectService.selectContacts({action: 'new_group'}).then(function (userIDs) { - if (userIDs.length == 1) { - $scope.dialogSelect(AppUsersManager.getUserString(userIDs[0])) - } else if (userIDs.length > 1) { + if (userIDs && + userIDs.length) { var scope = $rootScope.$new() scope.userIDs = userIDs