Skip to content

Commit 8056ccb

Browse files
committed
Implement empty arrays
1 parent 8686f8d commit 8056ccb

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

CHANGELOG.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,11 @@
22

33
All notable changes to `misfits/toastr` will be documented in this file.
44

5-
## 1.1.0 - XXXX-XX-XX
5+
## 1.2.0 - 2018-06-26
6+
7+
- Fix #5 Implement default arrays for the functions.
8+
9+
## 1.1.0 - 2018-06-25
610

711
- Fix #1 | Fix typo. (`signleton` to `singleton`)
812

src/Toastr.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ public function info(string $message, ?string $title = null, array $options = []
135135
* @param array $options User defined Toastr notification options
136136
* @return bool|void Return whether the notifications are successfully created or not.
137137
*/
138-
public function error(string $message, ?string $title = null, array $options): void
138+
public function error(string $message, ?string $title = null, array $options = []): void
139139
{
140140
$this->add('error', $message, $title, $options);
141141
}
@@ -148,7 +148,7 @@ public function error(string $message, ?string $title = null, array $options): v
148148
* @param string $options User defined Toastr notification options
149149
* @return bool|void Return whether the notification are successfully created or not.
150150
*/
151-
public function success(string $message, ?string $title = null, array $options): void
151+
public function success(string $message, ?string $title = null, array $options = []): void
152152
{
153153
$this->add('success', $message, $title, $options);
154154
}
@@ -161,7 +161,7 @@ public function success(string $message, ?string $title = null, array $options):
161161
* @param string $options User defined Toastr notification options
162162
* @return bool|void Return whether the notification are successfully created or not.
163163
*/
164-
public function warning(string $message, ?string $title = null, array $options): void
164+
public function warning(string $message, ?string $title = null, array $options = []): void
165165
{
166166
$this->add('warning', $message, $title, $options);
167167
}

0 commit comments

Comments
 (0)