Skip to content

Commit 29869ca

Browse files
committed
change warning function name to keep consistency
1 parent 8d29cc7 commit 29869ca

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ use Buffer\Bufflog;
2424

2525
Bufflog::debug("I am a debug");
2626
Bufflog::info("I am an info");
27-
Bufflog::warn("I am a warning");
27+
Bufflog::warning("I am a warning");
2828
Bufflog::error("I am an error");
2929
Bufflog::critical("I am a warning");
3030
```
@@ -33,7 +33,7 @@ If you wish add more context in your logs,
3333
```php
3434
Bufflog::debug("some context", ["my key" => " my value"]);
3535
Bufflog::info("I am a info with context", ["my key" => " my value"]);
36-
Bufflog::warn("I am a warning", ["duration" => "40ms"]);
36+
Bufflog::warning("I am a warning", ["duration" => "40ms"]);
3737

3838
Bufflog::critical("I'm critical log, here some extra fancy informations",
3939
[

example.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
Bufflog::info("I am an info");
1111
Bufflog::info("I am a info with context", ["my key" => " my value"]);
1212

13-
Bufflog::warn("I am a warning");
14-
Bufflog::warn("I am a warning", ["duration" => "40ms"]);
13+
Bufflog::warning("I am a warning");
14+
Bufflog::warning("I am a warning", ["duration" => "40ms"]);
1515

1616
Bufflog::error("I am an error");
1717
Bufflog::error("I am an error", ["mean" => "70"]);

src/php-bufflog/BuffLog.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ public static function info($message, $context = [], $extra = [])
5252
self::getLogger()->info($logOutput);
5353
}
5454

55-
public static function warn($message, $context = [], $extra = [])
55+
public static function warning($message, $context = [], $extra = [])
5656
{
5757
self::setVerbosity();
5858
if (self::$currentVerbosity > Logger::WARNING) {

0 commit comments

Comments
 (0)