Skip to content

Commit d2a73a8

Browse files
authored
Merge pull request #23 from SauravKumal/master
Updated Docs
2 parents 11cf02c + 6ba1974 commit d2a73a8

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

README.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ Or you can simply change the default log channel in the .env
4242
LOG_CHANNEL=telegram
4343
```
4444

45-
Publish config file
45+
Publish config file and views
4646
```
4747
php artisan vendor:publish --provider "Logger\TelegramLoggerServiceProvider"
4848
```
@@ -71,6 +71,14 @@ For using this package you need to create Telegram bot
7171
4. Get token and add it to your .env file (it is written above)
7272
5. Go to your bot and send ``/start`` message
7373

74+
## Change log template at runtime
75+
76+
1. Change config for template.
77+
```php
78+
config(['telegram-logger.template'=>'laravel-telegram-logging::custom'])
79+
```
80+
2. Use `Log` as usual.
81+
7482
## Lumen support
7583

7684
To make it work with Lumen, you need also run two steps:

src/TelegramLoggerServiceProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ public function register()
2828
public function boot()
2929
{
3030
$this->loadViewsFrom(__DIR__.'/views', 'laravel-telegram-logging');
31-
$this->publishes([__DIR__.'/views' => base_path('resources/views/vendor/laravel-telegram-logging')],'views' );
31+
$this->publishes([__DIR__.'/views' => base_path('resources/views/vendor/laravel-telegram-logging')], 'views');
3232
$this->publishes([__DIR__ . '/../config/telegram-logger.php' => config_path('telegram-logger.php')], 'config');
3333
}
3434
}

0 commit comments

Comments
 (0)