Sha256: a553312ac32fb48d63351fff931fef89aac0ce81d1851310e82af992d48fb55e

Contents?: true

Size: 486 Bytes

Versions: 123

Compression:

Stored size: 486 Bytes

Contents

export const failureAction = (type, message = 'Request failed with status code 422') => (
  {
    type,
    payload: {
      messages: [message],
      result: new Error(message),
    },
  }
);

export const toastErrorAction = (message = 'Request failed with status code 422') => (
  {
    payload: {
      message: {
        message,
        sticky: true,
        type: 'error',
      },
    },
    type: 'TOASTS_ADD',
  }
);

export default {
  failureAction,
  toastErrorAction,
};

Version data entries

123 entries across 123 versions & 1 rubygems

Version Path
katello-4.3.1 webpack/services/api/testHelpers.js
katello-4.2.2 webpack/services/api/testHelpers.js
katello-4.3.0 webpack/services/api/testHelpers.js
katello-4.3.0.rc4 webpack/services/api/testHelpers.js
katello-4.3.0.rc3 webpack/services/api/testHelpers.js
katello-4.3.0.rc2.1 webpack/services/api/testHelpers.js
katello-4.3.0.rc2 webpack/services/api/testHelpers.js
katello-4.3.0.rc1 webpack/services/api/testHelpers.js
katello-4.2.1 webpack/services/api/testHelpers.js
katello-4.2.0.1 webpack/services/api/testHelpers.js
katello-4.1.4 webpack/services/api/testHelpers.js
katello-4.0.3 webpack/services/api/testHelpers.js
katello-4.2.0.1.rc3 webpack/services/api/testHelpers.js
katello-3.18.5 webpack/services/api/testHelpers.js
katello-4.2.0.1.rc2 webpack/services/api/testHelpers.js
katello-4.2.0.rc2 webpack/services/api/testHelpers.js
katello-4.1.3 webpack/services/api/testHelpers.js
katello-4.2.0.rc1 webpack/services/api/testHelpers.js
katello-4.0.2.1 webpack/services/api/testHelpers.js
katello-4.1.2.1 webpack/services/api/testHelpers.js