referrerpolicy=no-referrer-when-downgrade

Function pallet_template::pallet::dispatchables::cause_error

source ·
pub fn cause_error<T: Config>()
Expand description

An example dispatchable that may throw a custom error.

It checks that the caller is a signed origin and reads the current value from the Something storage item. If a current value exists, it is incremented by 1 and then written back to storage.

§Errors

The function will return an error under the following conditions:

§Warning: Doc-Only

This function is an automatically generated, and is doc-only, uncallable stub. See the real version in Pallet::cause_error.