This commit is contained in:
839 2019-08-18 22:24:39 +09:00
Родитель 3c062e92f8
Коммит 4cbf9c23cc
1 изменённых файлов: 8 добавлений и 2 удалений

Просмотреть файл

@ -6,14 +6,20 @@ async function run() {
try {
let payload: IncomingWebhookSendArguments = {};
const text = core.getInput('text');
switch (core.getInput('type')) {
const failedMention = core.getInput('failedMenthon');
const _type = core.getInput('type');
core.debug(`text: ${text}`);
core.debug(`failedMention: ${failedMention}`);
core.debug(`type: ${_type}`);
switch (_type) {
case 'auto':
throw new Error('not implement');
case 'success':
payload = successPayload(text);
break;
case 'failure':
payload = failurePayload(text, core.getInput('failedMenthon'));
payload = failurePayload(text, failedMention);
break;
default:
payload = JSON.parse(core.getInput('payload'));