From 4245bc1f2ce86585703279765d18967f61f6a197 Mon Sep 17 00:00:00 2001 From: Daniel Molina Date: Mon, 14 Apr 2014 18:29:58 +0200 Subject: [PATCH] Fix default view update when no lang is defined for the user --- src/sunstone/sunstone-server.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/sunstone/sunstone-server.rb b/src/sunstone/sunstone-server.rb index f152060f1b..0fb6c07e8e 100755 --- a/src/sunstone/sunstone-server.rb +++ b/src/sunstone/sunstone-server.rb @@ -360,10 +360,10 @@ post '/config' do error 500, "" end - session[:lang] = user['TEMPLATE/LANG'] - session[:vnc_wss] = user['TEMPLATE/VNC_WSS'] - session[:default_view] = user['TEMPLATE/DEFAULT_VIEW'] - session[:table_order] = user['TEMPLATE/TABLE_ORDER'] + session[:lang] = user['TEMPLATE/LANG'] if user['TEMPLATE/LANG'] + session[:vnc_wss] = user['TEMPLATE/VNC_WSS'] if user['TEMPLATE/VNC_WSS'] + session[:default_view] = user['TEMPLATE/DEFAULT_VIEW'] if user['TEMPLATE/DEFAULT_VIEW'] + session[:table_order] = user['TEMPLATE/TABLE_ORDER'] if user['TEMPLATE/TABLE_ORDER'] session[:display_name] = user[DISPLAY_NAME_XPATH] || user['NAME'] [200, ""]