code: public static CmsWorkplaceSettings initUserSettings(CmsObject cms, CmsWorkplaceSettings settings, boolean update) {
  
          if (settings == null) {
              settings = new CmsWorkplaceSettings();
          }
  
          // save current workplace user & user settings object
          CmsUser user;
          if (update) {
              try {
                  // read the user from db to get the latest user information if required
                  user = cms.readUser(cms.getRequestContext().getCurrentUser().getId());
              } catch (CmsException e) {
                  // can usually be ignored
                  if (LOG.isInfoEnabled()) {
                      LOG.info(e.getLocalizedMessage());
                  }
                  user = cms.getRequestContext().getCurrentUser();
              }
          } else {
              user = cms.getRequestContext().getCurrentUser();
          }
          // store the user and it's settings in the Workplace settings
          settings.setUser(user);
          settings.setUserSettings(new CmsUserSettings(user));
  
          // return the result settings
          return settings;
      }
docs: Updates the user settings in the given workplace settings for the current user, reading the user settings
  from the database if required.<p>
  
  @param cms the cms object for the current user
  @param settings the workplace settings to update (if <code>null</code> a new instance is created)
  @param update flag indicating if settings are only updated (user preferences)
  
  @return the current users workplace settings
  
  @see #initWorkplaceSettings(CmsObject, CmsWorkplaceSettings, boolean)