$ match. fix transaction starting with number
This commit is contained in:
parent
74d94579f9
commit
f7f1eb067b
@ -81,7 +81,7 @@ class ChannelsApi {
|
|||||||
public async $searchChannelsById(search: string): Promise<any[]> {
|
public async $searchChannelsById(search: string): Promise<any[]> {
|
||||||
try {
|
try {
|
||||||
// restrict search to valid id/short_id prefix formats
|
// restrict search to valid id/short_id prefix formats
|
||||||
let searchStripped = search.match(/^[0-9]+[0-9x]*/)?.[0] || '';
|
let searchStripped = search.match(/^[0-9]+[0-9x]*$/)?.[0] || '';
|
||||||
if (!searchStripped.length) {
|
if (!searchStripped.length) {
|
||||||
return [];
|
return [];
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user