The following pull request was submitted through Github.
It can be accessed and reviewed at: https://github.com/lxc/lxd/pull/6235

This e-mail was sent by the LXC bot, direct replies will not reach the author
unless they happen to be subscribed to this list.

=== Description (from pull-request) ===
Signed-off-by: Stéphane Graber <stgra...@ubuntu.com>
From eb6187cabfae1173702b7429be56905ee0563124 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?St=C3=A9phane=20Graber?= <stgra...@ubuntu.com>
Date: Tue, 24 Sep 2019 14:59:43 -0400
Subject: [PATCH] shared/generate: Support instance.Type
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Signed-off-by: Stéphane Graber <stgra...@ubuntu.com>
---
 shared/generate/db/mapping.go | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/shared/generate/db/mapping.go b/shared/generate/db/mapping.go
index 2a85e63ed0..ecb846db91 100644
--- a/shared/generate/db/mapping.go
+++ b/shared/generate/db/mapping.go
@@ -197,7 +197,7 @@ func (f *Field) ZeroValue() string {
        switch f.Type.Name {
        case "string":
                return `""`
-       case "int":
+       case "int", "instance.Type":
                // FIXME: we use -1 since at the moment integer criteria are
                // required to be positive.
                return "-1"
@@ -273,7 +273,8 @@ func IsColumnType(name string) bool {
 
 var columnarTypeNames = []string{
        "bool",
-       "string",
+       "instance.Type",
        "int",
+       "string",
        "time.Time",
 }
_______________________________________________
lxc-devel mailing list
lxc-devel@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-devel

Reply via email to