{"size": 1386, "ext": "js", "max_stars_repo_path": "build/utils/talentscategory/analyzers/AllTalentsAnalysis.js", "max_stars_repo_name": "kemijibola/untappedapiv2", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "build/utils/talentscategory/analyzers/AllTalentsAnalysis.js", "max_issues_repo_name": "kemijibola/untappedapiv2", "max_issues_repo_issues_event_min_datetime": "2020-04-13T00:49:55.000Z", "max_issues_repo_issues_event_max_datetime": "2021-05-09T08:21:35.000Z", "max_forks_repo_path": "build/utils/talentscategory/analyzers/AllTalentsAnalysis.js", "max_forks_repo_name": "kemijibola/untappedapiv2", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": 7, "max_forks_count": null, "avg_line_length": 40.7647058824, "max_line_length": 75, "alphanum_fraction": 0.5988455988}
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var interfaces_1 = require("../../../app/models/interfaces");
var AllTalentsAnalysis = /** @class */ (function () {
    function AllTalentsAnalysis() {
    }
    AllTalentsAnalysis.prototype.run = function (users) {
        var _this = this;
        var filteredCategories = [];
        users = users.sort(function (a, b) {
            return _this.getTime(a.createdAt) - _this.getTime(b.createdAt);
        });
        for (var _i = 0, users_1 = users; _i < users_1.length; _i++) {
            var user = users_1[_i];
            var filtered = Object.assign({
                user: user.user,
                displayName: user.displayName,
                displayPhoto: user.displayPhoto,
                shortDescription: user.shortDescription || "",
                categories: user.categories || [],
                reportType: interfaces_1.ReportType.AllTalents,
                userType: user.userType
            });
            filteredCategories = filteredCategories.concat([filtered]);
        }
        return filteredCategories;
    };
    AllTalentsAnalysis.prototype.getTime = function (date) {
        return date != null ? new Date(date).getTime() : 0;
    };
    return AllTalentsAnalysis;
}());
exports.AllTalentsAnalysis = AllTalentsAnalysis;
//# sourceMappingURL=AllTalentsAnalysis.js.map