github.com/status-im/status-go@v1.1.0/protocol/pushnotificationclient/migrations/migrations.go (about)

     1  // Code generated by go-bindata. DO NOT EDIT.
     2  // sources:
     3  // 1593601729_initial_schema.down.sql (144B)
     4  // 1593601729_initial_schema.up.sql (1.773kB)
     5  // 1597909626_add_server_type.down.sql (0)
     6  // 1597909626_add_server_type.up.sql (145B)
     7  // 1599053776_add_chat_id_and_type.down.sql (0)
     8  // 1599053776_add_chat_id_and_type.up.sql (264B)
     9  // doc.go (402B)
    10  
    11  package migrations
    12  
    13  import (
    14  	"bytes"
    15  	"compress/gzip"
    16  	"crypto/sha256"
    17  	"fmt"
    18  	"io"
    19  	"os"
    20  	"path/filepath"
    21  	"strings"
    22  	"time"
    23  )
    24  
    25  func bindataRead(data []byte, name string) ([]byte, error) {
    26  	gz, err := gzip.NewReader(bytes.NewBuffer(data))
    27  	if err != nil {
    28  		return nil, fmt.Errorf("read %q: %w", name, err)
    29  	}
    30  
    31  	var buf bytes.Buffer
    32  	_, err = io.Copy(&buf, gz)
    33  	clErr := gz.Close()
    34  
    35  	if err != nil {
    36  		return nil, fmt.Errorf("read %q: %w", name, err)
    37  	}
    38  	if clErr != nil {
    39  		return nil, err
    40  	}
    41  
    42  	return buf.Bytes(), nil
    43  }
    44  
    45  type asset struct {
    46  	bytes  []byte
    47  	info   os.FileInfo
    48  	digest [sha256.Size]byte
    49  }
    50  
    51  type bindataFileInfo struct {
    52  	name    string
    53  	size    int64
    54  	mode    os.FileMode
    55  	modTime time.Time
    56  }
    57  
    58  func (fi bindataFileInfo) Name() string {
    59  	return fi.name
    60  }
    61  func (fi bindataFileInfo) Size() int64 {
    62  	return fi.size
    63  }
    64  func (fi bindataFileInfo) Mode() os.FileMode {
    65  	return fi.mode
    66  }
    67  func (fi bindataFileInfo) ModTime() time.Time {
    68  	return fi.modTime
    69  }
    70  func (fi bindataFileInfo) IsDir() bool {
    71  	return false
    72  }
    73  func (fi bindataFileInfo) Sys() interface{} {
    74  	return nil
    75  }
    76  
    77  var __1593601729_initial_schemaDownSql = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x72\x09\xf2\x0f\x50\x08\x71\x74\xf2\x71\x55\x28\x28\x2d\xce\x88\xcf\xcb\x2f\xc9\x4c\xcb\x4c\x4e\x2c\xc9\xcc\xcf\x8b\x4f\xce\xc9\x4c\xcd\x2b\x89\x2f\x4e\x2d\x2a\x4b\x2d\x2a\xb6\xe6\x22\x46\x71\x66\x5e\x5a\x3e\x54\xa5\xa7\x9f\x8b\x6b\x84\x42\x66\x4a\x45\x3c\x5e\xd5\xf1\x05\xa5\x49\x39\x99\xc9\xf1\xd9\xa9\x95\xd6\x5c\x80\x00\x00\x00\xff\xff\x6d\xb4\xf8\x65\x90\x00\x00\x00")
    78  
    79  func _1593601729_initial_schemaDownSqlBytes() ([]byte, error) {
    80  	return bindataRead(
    81  		__1593601729_initial_schemaDownSql,
    82  		"1593601729_initial_schema.down.sql",
    83  	)
    84  }
    85  
    86  func _1593601729_initial_schemaDownSql() (*asset, error) {
    87  	bytes, err := _1593601729_initial_schemaDownSqlBytes()
    88  	if err != nil {
    89  		return nil, err
    90  	}
    91  
    92  	info := bindataFileInfo{name: "1593601729_initial_schema.down.sql", size: 144, mode: os.FileMode(0644), modTime: time.Unix(1700000000, 0)}
    93  	a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xa, 0x95, 0x55, 0x64, 0x38, 0x40, 0x16, 0xbf, 0x8b, 0x1c, 0x18, 0xb4, 0xc5, 0x7f, 0xd0, 0xb8, 0xf0, 0x3c, 0xa2, 0x82, 0xf8, 0x8d, 0x5a, 0xd3, 0xb6, 0x6e, 0xa3, 0xb4, 0xc, 0x9, 0x33, 0x0}}
    94  	return a, nil
    95  }
    96  
    97  var __1593601729_initial_schemaUpSql = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xac\x54\xc1\x8e\xdb\x20\x10\xbd\xfb\x2b\xe6\xb8\x91\x72\xe8\x7d\x4f\x4e\x96\x54\x96\x10\x6e\x13\x22\xe5\x86\x28\x9e\x5d\xa3\xb8\x78\x0b\x78\xd5\xfc\x7d\x85\x9d\x78\x93\xc5\xc5\x55\xba\x17\x4b\x1e\x1e\xa3\x79\x6f\x1e\x6f\xbd\x25\x39\x27\xc0\xf3\x15\x25\x50\x6c\x80\x95\x1c\xc8\xa1\xd8\xf1\x1d\xbc\x76\xae\x16\xa6\xf5\xfa\x59\x2b\xe9\x75\x6b\x84\x6a\x34\x1a\x2f\x1c\xda\x37\xb4\x0e\x1e\x32\x80\xd7\xee\x47\xa3\x95\x38\xe2\x09\x56\xb4\x5c\xf5\xf7\xd9\x9e\xd2\x65\x06\x60\xf1\x45\x3b\x8f\x16\x2b\x58\x95\x25\x25\x39\x83\x27\xb2\xc9\xf7\x94\xc3\x26\xa7\x3b\x72\x8b\x11\xd2\x43\xc1\xf8\xd8\x61\xc4\x7e\x09\xb8\x46\x3a\x2f\x2c\x7a\xab\xe7\x90\x01\x74\x12\xaa\xed\x4c\x0a\x25\x95\x42\xe7\x84\x6f\x8f\x68\x80\x93\x03\x0f\xc5\x3d\x2b\xbe\xef\xc9\xc3\x3b\xa7\x05\x94\x0c\xd6\x25\xdb\xd0\x62\xcd\x61\x4b\xbe\xd1\x7c\x4d\xb2\xc5\x63\x96\xdd\xa3\xdb\xaf\x0e\xad\xc6\x79\xdd\x06\x5c\x44\xf3\x72\x74\x12\xba\x8a\x2f\x45\xb3\x2f\x2f\xd8\xcf\x25\xa1\xcd\x73\x3b\xcb\x60\x70\x88\x48\x41\xb4\x71\x5e\x36\xcd\xd0\x5b\x57\xfd\x0e\x6e\x00\xd1\x86\x3e\x78\x2b\x58\xe1\x6d\x5a\xa5\xe0\x4e\xdd\x9a\xa8\x1e\x6b\xf4\x71\x8c\x65\x3c\xfa\xe7\xca\xe7\xad\x54\x47\xac\xc4\x4f\x74\x4e\xbe\x9c\xcd\x70\xfe\x99\xdc\xab\xaa\xa5\x9f\xd4\xe7\xd2\x69\x82\xff\x99\xe7\x7b\xdb\x5b\x0e\xc5\x57\x56\x6e\x49\x06\x70\x2f\x09\x17\x3e\xd7\x07\xf3\x34\x52\x56\xa8\xa5\xab\xb1\xfa\x3f\xb7\xf4\xf9\x30\x99\x0e\xff\x9e\x09\xae\xeb\x2d\x37\x86\x55\x84\x1a\x53\x0b\xad\x6d\x6d\xa2\x53\xb4\x80\x25\x24\x4c\x37\xed\xb0\xfb\xd7\x33\x64\xaa\xbd\xda\xcc\x25\x67\x87\x5a\x2c\x2f\x80\x6a\x8d\x97\x2a\x38\xcd\xf5\xc7\x43\xd5\x9d\x8c\xaf\xd1\x6b\x15\x34\xff\x3b\xdd\x91\xf0\x35\x7e\xf6\xdd\x14\xec\x89\x1c\x40\x57\xbf\x45\x32\x6c\xae\x7d\x51\xb2\x74\x30\xa5\x9e\xf6\xe2\x31\xfb\x13\x00\x00\xff\xff\xfb\x06\xc2\x3d\xed\x06\x00\x00")
    98  
    99  func _1593601729_initial_schemaUpSqlBytes() ([]byte, error) {
   100  	return bindataRead(
   101  		__1593601729_initial_schemaUpSql,
   102  		"1593601729_initial_schema.up.sql",
   103  	)
   104  }
   105  
   106  func _1593601729_initial_schemaUpSql() (*asset, error) {
   107  	bytes, err := _1593601729_initial_schemaUpSqlBytes()
   108  	if err != nil {
   109  		return nil, err
   110  	}
   111  
   112  	info := bindataFileInfo{name: "1593601729_initial_schema.up.sql", size: 1773, mode: os.FileMode(0644), modTime: time.Unix(1700000000, 0)}
   113  	a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x4e, 0x1e, 0x5, 0x35, 0x9, 0xb2, 0x2d, 0x6f, 0x33, 0x63, 0xa2, 0x7a, 0x5b, 0xd2, 0x2d, 0xcb, 0x79, 0x7e, 0x6, 0xb4, 0x9d, 0x35, 0xd8, 0x9b, 0x55, 0xe5, 0xf8, 0x44, 0xca, 0xa6, 0xf3, 0xd3}}
   114  	return a, nil
   115  }
   116  
   117  var __1597909626_add_server_typeDownSql = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x01\x00\x00\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00")
   118  
   119  func _1597909626_add_server_typeDownSqlBytes() ([]byte, error) {
   120  	return bindataRead(
   121  		__1597909626_add_server_typeDownSql,
   122  		"1597909626_add_server_type.down.sql",
   123  	)
   124  }
   125  
   126  func _1597909626_add_server_typeDownSql() (*asset, error) {
   127  	bytes, err := _1597909626_add_server_typeDownSqlBytes()
   128  	if err != nil {
   129  		return nil, err
   130  	}
   131  
   132  	info := bindataFileInfo{name: "1597909626_add_server_type.down.sql", size: 0, mode: os.FileMode(0644), modTime: time.Unix(1700000000, 0)}
   133  	a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xe3, 0xb0, 0xc4, 0x42, 0x98, 0xfc, 0x1c, 0x14, 0x9a, 0xfb, 0xf4, 0xc8, 0x99, 0x6f, 0xb9, 0x24, 0x27, 0xae, 0x41, 0xe4, 0x64, 0x9b, 0x93, 0x4c, 0xa4, 0x95, 0x99, 0x1b, 0x78, 0x52, 0xb8, 0x55}}
   134  	return a, nil
   135  }
   136  
   137  var __1597909626_add_server_typeUpSql = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x72\xf4\x09\x71\x0d\x52\x08\x71\x74\xf2\x71\x55\x28\x28\x2d\xce\x88\xcf\xcb\x2f\xc9\x4c\xcb\x4c\x4e\x2c\xc9\xcc\xcf\x8b\x4f\xce\xc9\x4c\xcd\x2b\x89\x2f\x4e\x2d\x2a\x4b\x2d\x2a\x56\x70\x74\x71\x51\x70\xf6\xf7\x09\xf5\xf5\x53\x80\x08\xc5\x97\x54\x16\xa4\x2a\x78\xfa\x85\x28\xb8\xb8\xba\x39\x86\xfa\x84\x28\x18\x59\x73\x85\x06\xb8\x38\x86\x10\x61\x5a\xb0\x6b\x08\x8a\x31\xb6\x20\xcd\x5c\x80\x00\x00\x00\xff\xff\x98\x88\x1e\xcd\x91\x00\x00\x00")
   138  
   139  func _1597909626_add_server_typeUpSqlBytes() ([]byte, error) {
   140  	return bindataRead(
   141  		__1597909626_add_server_typeUpSql,
   142  		"1597909626_add_server_type.up.sql",
   143  	)
   144  }
   145  
   146  func _1597909626_add_server_typeUpSql() (*asset, error) {
   147  	bytes, err := _1597909626_add_server_typeUpSqlBytes()
   148  	if err != nil {
   149  		return nil, err
   150  	}
   151  
   152  	info := bindataFileInfo{name: "1597909626_add_server_type.up.sql", size: 145, mode: os.FileMode(0644), modTime: time.Unix(1700000000, 0)}
   153  	a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xc8, 0x3f, 0xe0, 0xe7, 0x57, 0x0, 0x5d, 0x60, 0xf3, 0x55, 0x64, 0x71, 0x80, 0x3c, 0xca, 0x8, 0x61, 0xb5, 0x3c, 0xe, 0xa1, 0xe4, 0x61, 0xd1, 0x4e, 0xd8, 0xb2, 0x55, 0xdd, 0x87, 0x62, 0x9b}}
   154  	return a, nil
   155  }
   156  
   157  var __1599053776_add_chat_id_and_typeDownSql = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x01\x00\x00\xff\xff\x00\x00\x00\x00\x00\x00\x00\x00")
   158  
   159  func _1599053776_add_chat_id_and_typeDownSqlBytes() ([]byte, error) {
   160  	return bindataRead(
   161  		__1599053776_add_chat_id_and_typeDownSql,
   162  		"1599053776_add_chat_id_and_type.down.sql",
   163  	)
   164  }
   165  
   166  func _1599053776_add_chat_id_and_typeDownSql() (*asset, error) {
   167  	bytes, err := _1599053776_add_chat_id_and_typeDownSqlBytes()
   168  	if err != nil {
   169  		return nil, err
   170  	}
   171  
   172  	info := bindataFileInfo{name: "1599053776_add_chat_id_and_type.down.sql", size: 0, mode: os.FileMode(0644), modTime: time.Unix(1700000000, 0)}
   173  	a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xe3, 0xb0, 0xc4, 0x42, 0x98, 0xfc, 0x1c, 0x14, 0x9a, 0xfb, 0xf4, 0xc8, 0x99, 0x6f, 0xb9, 0x24, 0x27, 0xae, 0x41, 0xe4, 0x64, 0x9b, 0x93, 0x4c, 0xa4, 0x95, 0x99, 0x1b, 0x78, 0x52, 0xb8, 0x55}}
   174  	return a, nil
   175  }
   176  
   177  var __1599053776_add_chat_id_and_typeUpSql = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x72\xf4\x09\x71\x0d\x52\x08\x71\x74\xf2\x71\x55\x28\x28\x2d\xce\x88\xcf\xcb\x2f\xc9\x4c\xcb\x4c\x4e\x2c\xc9\xcc\xcf\x8b\x4f\xce\xc9\x4c\xcd\x2b\x89\x2f\x06\x11\xc8\x12\xc5\x0a\x8e\x2e\x2e\x0a\xce\xfe\x3e\xa1\xbe\x7e\x0a\xc9\x19\x89\x25\xf1\x99\x29\x0a\x21\xae\x11\x21\xd6\x5c\x54\x30\x10\x45\x47\x49\x65\x41\xaa\x82\xa7\x5f\x88\x35\x17\x57\x68\x80\x8b\x63\x08\x69\xa6\x06\xbb\x86\xc0\xdd\x67\xab\xa0\xa4\xa4\x83\xc5\x70\x5b\x05\x43\x6b\x2e\x40\x00\x00\x00\xff\xff\x22\xaf\x2b\x87\x08\x01\x00\x00")
   178  
   179  func _1599053776_add_chat_id_and_typeUpSqlBytes() ([]byte, error) {
   180  	return bindataRead(
   181  		__1599053776_add_chat_id_and_typeUpSql,
   182  		"1599053776_add_chat_id_and_type.up.sql",
   183  	)
   184  }
   185  
   186  func _1599053776_add_chat_id_and_typeUpSql() (*asset, error) {
   187  	bytes, err := _1599053776_add_chat_id_and_typeUpSqlBytes()
   188  	if err != nil {
   189  		return nil, err
   190  	}
   191  
   192  	info := bindataFileInfo{name: "1599053776_add_chat_id_and_type.up.sql", size: 264, mode: os.FileMode(0644), modTime: time.Unix(1700000000, 0)}
   193  	a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xea, 0x7a, 0xf9, 0xc4, 0xa2, 0x96, 0x2e, 0xf9, 0x8f, 0x7, 0xf1, 0x1e, 0x73, 0x8a, 0xa6, 0x3a, 0x13, 0x4, 0x73, 0x82, 0x83, 0xb, 0xe3, 0xb5, 0x3b, 0x7e, 0xd, 0x23, 0xce, 0x98, 0xd4, 0xdc}}
   194  	return a, nil
   195  }
   196  
   197  var _docGo = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x84\x8f\x3d\x6a\x04\x31\x0c\x85\xfb\x39\xc5\x63\x9b\x6d\x32\x76\x02\x81\x40\x20\x45\xca\xf4\xb9\x80\xd6\xd6\xd8\x62\xc7\xf6\x60\x69\xff\x6e\x1f\x66\xb3\x90\xe9\xa2\xf2\x43\xdf\xd3\x93\xf7\xf8\xce\xa2\x98\x64\x66\x88\xa2\x72\x60\x55\xea\x37\x1c\x38\xd0\x49\x19\xbb\x24\x96\x4f\x07\x17\x5a\xf1\x6a\x64\x27\x1d\xa5\xf8\x22\xa9\x93\xb1\x3f\xbf\xee\x06\xef\x11\xa8\xee\x0d\x99\x6a\x9c\xf9\x9e\xa5\x50\xa3\x6e\x52\x13\x2e\x62\x19\x84\xa5\xf3\x24\x57\x87\x4f\xc3\xcc\xa4\x06\xcb\x64\x7b\x85\x65\x46\x20\xe5\x35\x66\x6a\x1d\xa9\x8d\x07\xa9\x91\x8c\xdc\x8a\xbe\xa6\x0d\x59\x1b\x06\x9a\x67\x8e\x98\x7a\x2b\x77\x57\xa9\x30\xa2\x74\x0e\xd6\xfa\xed\x09\xa4\xca\x86\x4a\x85\x75\xf5\x33\x9d\x19\xb5\x3d\xce\x83\x6a\xfc\xff\x23\x5c\x5a\x3f\x2a\x48\xc1\xd7\x85\x83\x71\x74\xc3\xb0\x50\x38\x52\x62\xfc\xee\x49\xab\x3a\x0c\xde\xa7\xf6\x9e\xb8\xf2\x6a\x6e\x7b\x8e\xa5\x45\x93\xc2\x1f\x2f\x6f\xcf\x8f\xc1\xb8\x1c\xd3\xc6\xc6\xd8\xe0\x9c\xff\x03\x2e\x35\x38\x3f\xfc\x04\x00\x00\xff\xff\xdd\xba\x79\x90\x92\x01\x00\x00")
   198  
   199  func docGoBytes() ([]byte, error) {
   200  	return bindataRead(
   201  		_docGo,
   202  		"doc.go",
   203  	)
   204  }
   205  
   206  func docGo() (*asset, error) {
   207  	bytes, err := docGoBytes()
   208  	if err != nil {
   209  		return nil, err
   210  	}
   211  
   212  	info := bindataFileInfo{name: "doc.go", size: 402, mode: os.FileMode(0644), modTime: time.Unix(1700000000, 0)}
   213  	a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xf1, 0x48, 0xd2, 0x42, 0xd0, 0x5f, 0xf4, 0x53, 0xfe, 0xa5, 0x44, 0xc, 0x8b, 0x6b, 0xed, 0xca, 0xc, 0xc0, 0xd8, 0x2e, 0x90, 0x87, 0x5b, 0x92, 0x6d, 0xa1, 0xf8, 0x15, 0x23, 0x96, 0xdb, 0x11}}
   214  	return a, nil
   215  }
   216  
   217  // Asset loads and returns the asset for the given name.
   218  // It returns an error if the asset could not be found or
   219  // could not be loaded.
   220  func Asset(name string) ([]byte, error) {
   221  	canonicalName := strings.Replace(name, "\\", "/", -1)
   222  	if f, ok := _bindata[canonicalName]; ok {
   223  		a, err := f()
   224  		if err != nil {
   225  			return nil, fmt.Errorf("Asset %s can't read by error: %v", name, err)
   226  		}
   227  		return a.bytes, nil
   228  	}
   229  	return nil, fmt.Errorf("Asset %s not found", name)
   230  }
   231  
   232  // AssetString returns the asset contents as a string (instead of a []byte).
   233  func AssetString(name string) (string, error) {
   234  	data, err := Asset(name)
   235  	return string(data), err
   236  }
   237  
   238  // MustAsset is like Asset but panics when Asset would return an error.
   239  // It simplifies safe initialization of global variables.
   240  func MustAsset(name string) []byte {
   241  	a, err := Asset(name)
   242  	if err != nil {
   243  		panic("asset: Asset(" + name + "): " + err.Error())
   244  	}
   245  
   246  	return a
   247  }
   248  
   249  // MustAssetString is like AssetString but panics when Asset would return an
   250  // error. It simplifies safe initialization of global variables.
   251  func MustAssetString(name string) string {
   252  	return string(MustAsset(name))
   253  }
   254  
   255  // AssetInfo loads and returns the asset info for the given name.
   256  // It returns an error if the asset could not be found or
   257  // could not be loaded.
   258  func AssetInfo(name string) (os.FileInfo, error) {
   259  	canonicalName := strings.Replace(name, "\\", "/", -1)
   260  	if f, ok := _bindata[canonicalName]; ok {
   261  		a, err := f()
   262  		if err != nil {
   263  			return nil, fmt.Errorf("AssetInfo %s can't read by error: %v", name, err)
   264  		}
   265  		return a.info, nil
   266  	}
   267  	return nil, fmt.Errorf("AssetInfo %s not found", name)
   268  }
   269  
   270  // AssetDigest returns the digest of the file with the given name. It returns an
   271  // error if the asset could not be found or the digest could not be loaded.
   272  func AssetDigest(name string) ([sha256.Size]byte, error) {
   273  	canonicalName := strings.Replace(name, "\\", "/", -1)
   274  	if f, ok := _bindata[canonicalName]; ok {
   275  		a, err := f()
   276  		if err != nil {
   277  			return [sha256.Size]byte{}, fmt.Errorf("AssetDigest %s can't read by error: %v", name, err)
   278  		}
   279  		return a.digest, nil
   280  	}
   281  	return [sha256.Size]byte{}, fmt.Errorf("AssetDigest %s not found", name)
   282  }
   283  
   284  // Digests returns a map of all known files and their checksums.
   285  func Digests() (map[string][sha256.Size]byte, error) {
   286  	mp := make(map[string][sha256.Size]byte, len(_bindata))
   287  	for name := range _bindata {
   288  		a, err := _bindata[name]()
   289  		if err != nil {
   290  			return nil, err
   291  		}
   292  		mp[name] = a.digest
   293  	}
   294  	return mp, nil
   295  }
   296  
   297  // AssetNames returns the names of the assets.
   298  func AssetNames() []string {
   299  	names := make([]string, 0, len(_bindata))
   300  	for name := range _bindata {
   301  		names = append(names, name)
   302  	}
   303  	return names
   304  }
   305  
   306  // _bindata is a table, holding each asset generator, mapped to its name.
   307  var _bindata = map[string]func() (*asset, error){
   308  	"1593601729_initial_schema.down.sql":       _1593601729_initial_schemaDownSql,
   309  	"1593601729_initial_schema.up.sql":         _1593601729_initial_schemaUpSql,
   310  	"1597909626_add_server_type.down.sql":      _1597909626_add_server_typeDownSql,
   311  	"1597909626_add_server_type.up.sql":        _1597909626_add_server_typeUpSql,
   312  	"1599053776_add_chat_id_and_type.down.sql": _1599053776_add_chat_id_and_typeDownSql,
   313  	"1599053776_add_chat_id_and_type.up.sql":   _1599053776_add_chat_id_and_typeUpSql,
   314  	"doc.go":                                   docGo,
   315  }
   316  
   317  // AssetDebug is true if the assets were built with the debug flag enabled.
   318  const AssetDebug = false
   319  
   320  // AssetDir returns the file names below a certain
   321  // directory embedded in the file by go-bindata.
   322  // For example if you run go-bindata on data/... and data contains the
   323  // following hierarchy:
   324  //
   325  //	data/
   326  //	  foo.txt
   327  //	  img/
   328  //	    a.png
   329  //	    b.png
   330  //
   331  // then AssetDir("data") would return []string{"foo.txt", "img"},
   332  // AssetDir("data/img") would return []string{"a.png", "b.png"},
   333  // AssetDir("foo.txt") and AssetDir("notexist") would return an error, and
   334  // AssetDir("") will return []string{"data"}.
   335  func AssetDir(name string) ([]string, error) {
   336  	node := _bintree
   337  	if len(name) != 0 {
   338  		canonicalName := strings.Replace(name, "\\", "/", -1)
   339  		pathList := strings.Split(canonicalName, "/")
   340  		for _, p := range pathList {
   341  			node = node.Children[p]
   342  			if node == nil {
   343  				return nil, fmt.Errorf("Asset %s not found", name)
   344  			}
   345  		}
   346  	}
   347  	if node.Func != nil {
   348  		return nil, fmt.Errorf("Asset %s not found", name)
   349  	}
   350  	rv := make([]string, 0, len(node.Children))
   351  	for childName := range node.Children {
   352  		rv = append(rv, childName)
   353  	}
   354  	return rv, nil
   355  }
   356  
   357  type bintree struct {
   358  	Func     func() (*asset, error)
   359  	Children map[string]*bintree
   360  }
   361  
   362  var _bintree = &bintree{nil, map[string]*bintree{
   363  	"1593601729_initial_schema.down.sql":       {_1593601729_initial_schemaDownSql, map[string]*bintree{}},
   364  	"1593601729_initial_schema.up.sql":         {_1593601729_initial_schemaUpSql, map[string]*bintree{}},
   365  	"1597909626_add_server_type.down.sql":      {_1597909626_add_server_typeDownSql, map[string]*bintree{}},
   366  	"1597909626_add_server_type.up.sql":        {_1597909626_add_server_typeUpSql, map[string]*bintree{}},
   367  	"1599053776_add_chat_id_and_type.down.sql": {_1599053776_add_chat_id_and_typeDownSql, map[string]*bintree{}},
   368  	"1599053776_add_chat_id_and_type.up.sql":   {_1599053776_add_chat_id_and_typeUpSql, map[string]*bintree{}},
   369  	"doc.go":                                   {docGo, map[string]*bintree{}},
   370  }}
   371  
   372  // RestoreAsset restores an asset under the given directory.
   373  func RestoreAsset(dir, name string) error {
   374  	data, err := Asset(name)
   375  	if err != nil {
   376  		return err
   377  	}
   378  	info, err := AssetInfo(name)
   379  	if err != nil {
   380  		return err
   381  	}
   382  	err = os.MkdirAll(_filePath(dir, filepath.Dir(name)), os.FileMode(0755))
   383  	if err != nil {
   384  		return err
   385  	}
   386  	err = os.WriteFile(_filePath(dir, name), data, info.Mode())
   387  	if err != nil {
   388  		return err
   389  	}
   390  	return os.Chtimes(_filePath(dir, name), info.ModTime(), info.ModTime())
   391  }
   392  
   393  // RestoreAssets restores an asset under the given directory recursively.
   394  func RestoreAssets(dir, name string) error {
   395  	children, err := AssetDir(name)
   396  	// File
   397  	if err != nil {
   398  		return RestoreAsset(dir, name)
   399  	}
   400  	// Dir
   401  	for _, child := range children {
   402  		err = RestoreAssets(dir, filepath.Join(name, child))
   403  		if err != nil {
   404  			return err
   405  		}
   406  	}
   407  	return nil
   408  }
   409  
   410  func _filePath(dir, name string) string {
   411  	canonicalName := strings.Replace(name, "\\", "/", -1)
   412  	return filepath.Join(append([]string{dir}, strings.Split(canonicalName, "/")...)...)
   413  }