瀏覽代碼

fix counts

Chris Mague 7 年之前
父節點
當前提交
186c07f814
共有 1 個文件被更改,包括 2 次插入3 次删除
  1. 2 3
      lib/neoinfra/vpcs.rb

+ 2 - 3
lib/neoinfra/vpcs.rb

@@ -18,12 +18,11 @@ module NeoInfra
     end
 
     def non_default_vpc_count
-      p Vpc.all
-      21
+      Vpc.all.collect{|x| x.default}.select{|y| y == "false"}.length
     end
 
     def default_vpc_count
-      22
+      Vpc.all.collect{|x| x.default}.select{|y| y == "true"}.length
     end
 
     def list_vpcs