# $onlyIfSet — Stops the script with a message while a setting is empty

## Syntax

```
$onlyIfSet[variable;message;(scope);(target);(guildID)]
```

## Parameters

- **variable** *(text, required)* — The setting.
- **message** *(text, required)* — Sent when the setting is empty, then the script stops.
- **scope** *(text, optional)* — Same as `$increment`. Default: `server`.
- **target** *(ID, optional)* — Same as `$increment`.
- **guildID** *(ID, optional)* — Same as `$increment`.

## Return Value

- empty.

## Usage

```
$onlyIfSet[logChannel;An admin must set the log channel first.]
```

## Example

```bdfd
$sendMessage[$onlyIfSet[logChannel;An admin must set the log channel first.]]
```
