Skip to content

Commit

Permalink
Merge pull request #39 from nazarovctrl/30-update-version
Browse files Browse the repository at this point in the history
30 update version
  • Loading branch information
nazarovctrl authored Apr 6, 2024
2 parents ccddcd6 + 582fa84 commit 59cc634
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 50 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
## [Java documentation](https://javadoc.io/doc/io.github.nazarovctrl/telegram-bot-spring/1.0.5)
## Library [link](https://central.sonatype.com/artifact/io.github.nazarovctrl/telegram-bot-spring/1.0.5) in Maven Central
## [Java documentation](https://javadoc.io/doc/io.github.nazarovctrl/telegram-bot-spring/1.0.6)
## Library [link](https://central.sonatype.com/artifact/io.github.nazarovctrl/telegram-bot-spring/1.0.6) in Maven Central
## Maven dependency

<dependency>
<groupId>io.github.nazarovctrl</groupId>
<artifactId>telegram-bot-spring</artifactId>
<version>1.0.5</version>
<version>1.0.6</version>
</dependency>

## How to use library?
Expand Down
14 changes: 7 additions & 7 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,18 @@
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>3.1.2</version>
<version>3.1.4</version>
<relativePath/>
</parent>

<properties>
<java.version>17</java.version>
</properties>

<groupId>io.github.nazarovctrl</groupId>
<artifactId>telegram-bot-spring</artifactId>
<packaging>jar</packaging>
<version>1.0.5</version>
<version>1.0.6</version>
<name>${project.groupId}:${project.artifactId}</name>
<description>Library to make it easier to create a telegram-bot in spring</description>
<url>https://github.com/nazarovctrl/telegram-bot-spring</url>
Expand Down Expand Up @@ -41,7 +45,7 @@
<name>Azimjon Nazarov</name>
<email>[email protected]</email>
<organization>io.github.nazarovctrl</organization>
<organizationUrl>http://github.com/nazarovctrl/</organizationUrl>
<organizationUrl>https://github.com/nazarovctrl/</organizationUrl>
</developer>
</developers>

Expand All @@ -51,10 +55,6 @@
<url>https://github.com/nazarovctrl/telegram-bot-spring/tree/master</url>
</scm>

<properties>
<java.version>17</java.version>
</properties>

<profiles>
<profile>
<id>release</id>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public class MessageSender extends DefaultAbsSender {
/**
* @param botConfig bean used to get telegram bot token
*/
public MessageSender(CtrlBotOptions botOptions, BotConfig botConfig) {
public MessageSender(TelegramBotAPIOptions botOptions, BotConfig botConfig) {
super(botOptions, botConfig.getToken());
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,13 @@
import org.springframework.stereotype.Component;
import org.telegram.telegrambots.bots.DefaultBotOptions;

/**
* The class for changing base_url
*
* @author Azimjon Nazarov
*/
@Component
public class CtrlBotOptions extends DefaultBotOptions {
public class TelegramBotAPIOptions extends DefaultBotOptions {
@Value("${bot.base_url:https://api.telegram.org/bot}")
private String base_url;

Expand Down

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package io.github.nazarovctrl.telegrambotspring.longpolling;

import io.github.nazarovctrl.telegrambotspring.bot.BotConfig;
import io.github.nazarovctrl.telegrambotspring.bot.CtrlBotOptions;
import io.github.nazarovctrl.telegrambotspring.bot.TelegramBotAPIOptions;
import io.github.nazarovctrl.telegrambotspring.controller.AbstractUpdateController;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;
Expand Down Expand Up @@ -33,7 +33,7 @@ public class TelegramLongPollingBot extends org.telegram.telegrambots.bots.Teleg
* @param botConfig bean
* @param updateController bean
*/
public TelegramLongPollingBot(CtrlBotOptions options, BotConfig botConfig, AbstractUpdateController updateController) throws TelegramApiException {
public TelegramLongPollingBot(TelegramBotAPIOptions options, BotConfig botConfig, AbstractUpdateController updateController) throws TelegramApiException {
super(options, botConfig.getToken());
this.botConfig = botConfig;
this.updateController = updateController;
Expand Down

0 comments on commit 59cc634

Please sign in to comment.