mirror of
https://github.com/moparisthebest/Yaaic
synced 2024-11-15 13:35:09 -05:00
Ignore case of conversation's name
This commit is contained in:
parent
7376ba7856
commit
5f3948e6c5
@ -103,7 +103,7 @@ public class DeckAdapter extends BaseAdapter
|
||||
public int getPositionByName(String name)
|
||||
{
|
||||
for (int i = 0; i < conversations.size(); i++) {
|
||||
if (conversations.get(i).getName().equals(name)) {
|
||||
if (conversations.get(i).getName().equalsIgnoreCase(name)) {
|
||||
return i;
|
||||
}
|
||||
}
|
||||
|
@ -61,7 +61,7 @@ public abstract class Conversation
|
||||
{
|
||||
this.buffer = Collections.synchronizedList(new LinkedList<Message>());
|
||||
this.history = Collections.synchronizedList(new LinkedList<Message>());
|
||||
this.name = name;
|
||||
this.name = name.toLowerCase();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -229,7 +229,7 @@ public class Server
|
||||
*/
|
||||
public Conversation getConversation(String name)
|
||||
{
|
||||
return conversations.get(name);
|
||||
return conversations.get(name.toLowerCase());
|
||||
}
|
||||
|
||||
/**
|
||||
@ -239,7 +239,7 @@ public class Server
|
||||
*/
|
||||
public void addConversationl(Conversation conversation)
|
||||
{
|
||||
conversations.put(conversation.getName(), conversation);
|
||||
conversations.put(conversation.getName().toLowerCase(), conversation);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -249,7 +249,7 @@ public class Server
|
||||
*/
|
||||
public void removeConversation(String name)
|
||||
{
|
||||
conversations.remove(name);
|
||||
conversations.remove(name.toLowerCase());
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user