'use strict';

const dataModel = require('./data-model-c51de090.js');

const getUserInitials = (user) => `${user.firstName[0]}${user.lastName[0]}`;
const getUserFullName = (user) => `${user.firstName} ${user.lastName}`;
class User extends dataModel.DataModel {
  static decode(json) {
    return Object.assign(Object.create(User.prototype), json);
  }
  static generateRef(id) {
    return { _ref: 'kimlik-users', _id: id };
  }
}

exports.User = User;
exports.getUserFullName = getUserFullName;
exports.getUserInitials = getUserInitials;
