mirror of
https://github.com/Threnklyn/MinecraftChat.git
synced 2026-05-24 06:58:28 +02:00
Connect on select() if credentials are already set
This commit is contained in:
@@ -9,6 +9,11 @@ module.exports = function($scope, socket, servers) {
|
||||
$scope.select = function(id) {
|
||||
$scope.ip = servers.select(id).ip;
|
||||
$scope.port = servers.select(id).port;
|
||||
|
||||
if ($scope.username.length > 0 && $scope.password.length > 0) {
|
||||
$scope.connect();
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
// connect handler
|
||||
|
||||
Reference in New Issue
Block a user