Must be one of the following:
feat: A new feature. fix: A bug fix. docs: Documentation only changes. style: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc). refactor: A code change that neither fixes a bug nor adds a feature. perf: A code change that improves performance. test: Adding missing tests. chore: Changes to the build process or auxiliary tools and libraries such as documentation generation.
Initial commit 🎉 🎉
New feature ✨ ✨
Bugfix 🐛 🐛
Documentation 📚 📚
Performance 🐎 🐎
Tests 🚨 🚨
Refactor code 🔨 🔨
Removing code/files 🔥 🔥
Adding CI build system 👷 👷
Security 🔒 🔒
Upgrading dependencies ⬆️ ⬆️
Downgrading dependencies ⬇️ ⬇️
Critical hotfix 🚑 🚑
Work in progress 🚧 🚧
Lint 👕 👕
Configuration files 🔧 🔧
{
const statusOrder = { "pending": -2, "validated": -1, "rejected": 1 };
const aStatus = a.status.toLowerCase();
const bStatus = b.status.toLowerCase();
if (statusOrder[aStatus] === undefined && statusOrder[bStatus] === undefined) {
return 0;
} else if (statusOrder[aStatus] === undefined) {
return 1;
} else if (statusOrder[bStatus] === undefined) {
return -1;
} else {
return statusOrder[aStatus] - statusOrder[bStatus];
}
}