You could as well write return this.id || this.getAsString("uid");