[ARVADOS] updated: 851f7d9cc9d3f6e4843a8fbd507338b1cc0e9f2c

git at public.curoverse.com git at public.curoverse.com
Mon Mar 17 15:01:14 EDT 2014


Summary of changes:
 .../app/controllers/arvados/v1/users_controller.rb |    4 ++--
 .../functional/arvados/v1/users_controller_test.rb |    1 -
 2 files changed, 2 insertions(+), 3 deletions(-)

       via  851f7d9cc9d3f6e4843a8fbd507338b1cc0e9f2c (commit)
      from  107377eaf36cba7130e7bc9f42111147049cbd0b (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 851f7d9cc9d3f6e4843a8fbd507338b1cc0e9f2c
Author: radhika chippada <radhika at radhika.curoverse>
Date:   Mon Mar 17 15:00:45 2014 -0400

    Fix a nil check

diff --git a/services/api/app/controllers/arvados/v1/users_controller.rb b/services/api/app/controllers/arvados/v1/users_controller.rb
index 04d0db7..0d22b86 100644
--- a/services/api/app/controllers/arvados/v1/users_controller.rb
+++ b/services/api/app/controllers/arvados/v1/users_controller.rb
@@ -185,7 +185,7 @@ class Arvados::V1::UsersController < ApplicationController
 	
 	# link the repo_name passed
 	def create_user_repo_link(repo_name)
-		if !repo_name
+		if not repo_name
 			logger.warn ("Repository name not given for #{@object[:uuid]}. Skip creating the link")
 			return
 		end
@@ -226,7 +226,7 @@ class Arvados::V1::UsersController < ApplicationController
 			vm = (vms = VirtualMachine.where(uuid: vm_uuid)) != nil ? vms.first : nil
   		#vm = VirtualMachine.where(uuid: vm_uuid)
 
-			if [] == vm
+			if not vm
 			  logger.warn "Could not look up virtual machine with uuid #{vm_uuid.inspect}"
 				return
 			end
diff --git a/services/api/test/functional/arvados/v1/users_controller_test.rb b/services/api/test/functional/arvados/v1/users_controller_test.rb
index a2b282c..4e04363 100644
--- a/services/api/test/functional/arvados/v1/users_controller_test.rb
+++ b/services/api/test/functional/arvados/v1/users_controller_test.rb
@@ -68,7 +68,6 @@ class Arvados::V1::UsersControllerTest < ActionController::TestCase
     }
     assert_response :success
     created = JSON.parse(@response.body)
-puts "created = #{created}"
     assert_equal 'in_create_test_first_name', created['first_name']
     assert_not_nil created['uuid'], 'expected non-null uuid for the newly created user'
     assert_not_nil created['email'], 'since email was given, expected non-nil email'

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list