Commit 9f84c26a authored by Patrick Müller's avatar Patrick Müller

fix: Projects Panel -> open first project if only one project exists

(cherry picked from commit 32d93ab3)
parent b6aa9c53
......@@ -355,8 +355,19 @@ define('controls/projects/project/Panel', [;
Projects.getList(function (result) {
if (Object.getLength(result)) {
for (var key in result) {
var key;
if (Object.getLength(result) === 1) {
key = Object.keys(result)[0];
self.setAttribute('project', key);
self.setAttribute('lang', result[key].default_lang);
} else if (Object.getLength(result)) {
for (key in result) {
if (!result.hasOwnProperty(key)) {
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment