{"action":"created","comment":{"url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/comments/64722955","id":64722955,"diff_hunk":"@@ -42,11 +39,17 @@ def validate_disbursements\n     end\n   end\n \n-  def validate_warrant\n-    if @record.is_interim_warrant?\n-      add_error(:warrant, 'blank') if @record.claim.warrant_fee.nil?\n-    else\n-      add_error(:warrant, 'present') if @record.claim.warrant_fee.present?\n-    end\n+  def validate_warrant_issued_date\n+    return if !@record.is_interim_warrant?\n+    validate_presence(:warrant_issued_date, 'blank')","path":"app/validators/fee/interim_fee_validator.rb","position":45,"original_position":45,"commit_id":"2fede14397fec8aca398359dae8d4c6fdfde8f0c","original_commit_id":"2fede14397fec8aca398359dae8d4c6fdfde8f0c","user":{"login":"slorek","id":408371,"avatar_url":"https://avatars.githubusercontent.com/u/408371?v=3","gravatar_id":"","url":"https://api.github.com/users/slorek","html_url":"https://github.com/slorek","followers_url":"https://api.github.com/users/slorek/followers","following_url":"https://api.github.com/users/slorek/following{/other_user}","gists_url":"https://api.github.com/users/slorek/gists{/gist_id}","starred_url":"https://api.github.com/users/slorek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/slorek/subscriptions","organizations_url":"https://api.github.com/users/slorek/orgs","repos_url":"https://api.github.com/users/slorek/repos","events_url":"https://api.github.com/users/slorek/events{/privacy}","received_events_url":"https://api.github.com/users/slorek/received_events","type":"User","site_admin":false},"body":"I think Rubocop will enforce this if set.","created_at":"2016-05-26T10:21:31Z","updated_at":"2016-05-26T10:21:31Z","html_url":"https://github.com/ministryofjustice/advocate-defence-payments/pull/1465#discussion_r64722955","pull_request_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/1465","_links":{"self":{"href":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/comments/64722955"},"html":{"href":"https://github.com/ministryofjustice/advocate-defence-payments/pull/1465#discussion_r64722955"},"pull_request":{"href":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/1465"}}},"pull_request":{"url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/1465","id":71466766,"html_url":"https://github.com/ministryofjustice/advocate-defence-payments/pull/1465","diff_url":"https://github.com/ministryofjustice/advocate-defence-payments/pull/1465.diff","patch_url":"https://github.com/ministryofjustice/advocate-defence-payments/pull/1465.patch","issue_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/issues/1465","number":1465,"state":"closed","locked":false,"title":"change interim claim warrant fee to interim warrant","user":{"login":"jsugarman","id":7016425,"avatar_url":"https://avatars.githubusercontent.com/u/7016425?v=3","gravatar_id":"","url":"https://api.github.com/users/jsugarman","html_url":"https://github.com/jsugarman","followers_url":"https://api.github.com/users/jsugarman/followers","following_url":"https://api.github.com/users/jsugarman/following{/other_user}","gists_url":"https://api.github.com/users/jsugarman/gists{/gist_id}","starred_url":"https://api.github.com/users/jsugarman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsugarman/subscriptions","organizations_url":"https://api.github.com/users/jsugarman/orgs","repos_url":"https://api.github.com/users/jsugarman/repos","events_url":"https://api.github.com/users/jsugarman/events{/privacy}","received_events_url":"https://api.github.com/users/jsugarman/received_events","type":"User","site_admin":false},"body":"Interim claims were using \"final warrants\" (Fee::WarrantFee of type Fee::WarrantFeeType with code XWAR) objects for their warrant fees. This has been changed to use Interim fees of description warrant (Fee:InterimFee of type Fee::InterimFeeType with code of IWARR).\r\n\r\nThis necessitated changing validations (and error messages) as well as presenters which were also refactored. summary and claim details views were also changed in line with the changes.\r\n\r\nIn addition \"final warrants\" (Fee::WarrantFee) have been amended to require an amount, with commensurate changes to validators and presenters and specs\r\n\r\nfactories and spec modified in line with changes too.","created_at":"2016-05-25T21:32:45Z","updated_at":"2016-05-26T10:21:31Z","closed_at":"2016-05-26T10:18:16Z","merged_at":"2016-05-26T10:18:16Z","merge_commit_sha":"0030a6c9d0afdc06f3dd2f4e02c679c228dd31d5","assignee":{"login":"stephenrichards","id":115617,"avatar_url":"https://avatars.githubusercontent.com/u/115617?v=3","gravatar_id":"","url":"https://api.github.com/users/stephenrichards","html_url":"https://github.com/stephenrichards","followers_url":"https://api.github.com/users/stephenrichards/followers","following_url":"https://api.github.com/users/stephenrichards/following{/other_user}","gists_url":"https://api.github.com/users/stephenrichards/gists{/gist_id}","starred_url":"https://api.github.com/users/stephenrichards/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stephenrichards/subscriptions","organizations_url":"https://api.github.com/users/stephenrichards/orgs","repos_url":"https://api.github.com/users/stephenrichards/repos","events_url":"https://api.github.com/users/stephenrichards/events{/privacy}","received_events_url":"https://api.github.com/users/stephenrichards/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/1465/commits","review_comments_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/1465/comments","review_comment_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/issues/1465/comments","statuses_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/statuses/2fede14397fec8aca398359dae8d4c6fdfde8f0c","head":{"label":"ministryofjustice:change-interim-claim-warrant-from-final-to-interim","ref":"change-interim-claim-warrant-from-final-to-interim","sha":"2fede14397fec8aca398359dae8d4c6fdfde8f0c","user":{"login":"ministryofjustice","id":2203574,"avatar_url":"https://avatars.githubusercontent.com/u/2203574?v=3","gravatar_id":"","url":"https://api.github.com/users/ministryofjustice","html_url":"https://github.com/ministryofjustice","followers_url":"https://api.github.com/users/ministryofjustice/followers","following_url":"https://api.github.com/users/ministryofjustice/following{/other_user}","gists_url":"https://api.github.com/users/ministryofjustice/gists{/gist_id}","starred_url":"https://api.github.com/users/ministryofjustice/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ministryofjustice/subscriptions","organizations_url":"https://api.github.com/users/ministryofjustice/orgs","repos_url":"https://api.github.com/users/ministryofjustice/repos","events_url":"https://api.github.com/users/ministryofjustice/events{/privacy}","received_events_url":"https://api.github.com/users/ministryofjustice/received_events","type":"Organization","site_admin":false},"repo":{"id":32451549,"name":"advocate-defence-payments","full_name":"ministryofjustice/advocate-defence-payments","owner":{"login":"ministryofjustice","id":2203574,"avatar_url":"https://avatars.githubusercontent.com/u/2203574?v=3","gravatar_id":"","url":"https://api.github.com/users/ministryofjustice","html_url":"https://github.com/ministryofjustice","followers_url":"https://api.github.com/users/ministryofjustice/followers","following_url":"https://api.github.com/users/ministryofjustice/following{/other_user}","gists_url":"https://api.github.com/users/ministryofjustice/gists{/gist_id}","starred_url":"https://api.github.com/users/ministryofjustice/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ministryofjustice/subscriptions","organizations_url":"https://api.github.com/users/ministryofjustice/orgs","repos_url":"https://api.github.com/users/ministryofjustice/repos","events_url":"https://api.github.com/users/ministryofjustice/events{/privacy}","received_events_url":"https://api.github.com/users/ministryofjustice/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ministryofjustice/advocate-defence-payments","description":"Claim for crown court defence","fork":false,"url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments","forks_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/forks","keys_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/teams","hooks_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/hooks","issue_events_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/issues/events{/number}","events_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/events","assignees_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/assignees{/user}","branches_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/branches{/branch}","tags_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/tags","blobs_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/git/refs{/sha}","trees_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/statuses/{sha}","languages_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/languages","stargazers_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/stargazers","contributors_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/contributors","subscribers_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/subscribers","subscription_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/subscription","commits_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/commits{/sha}","git_commits_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/git/commits{/sha}","comments_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/comments{/number}","issue_comment_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/issues/comments{/number}","contents_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/contents/{+path}","compare_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/merges","archive_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/downloads","issues_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/issues{/number}","pulls_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls{/number}","milestones_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/milestones{/number}","notifications_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/labels{/name}","releases_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/releases{/id}","deployments_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/deployments","created_at":"2015-03-18T10:10:18Z","updated_at":"2016-03-17T13:20:38Z","pushed_at":"2016-05-26T10:18:19Z","git_url":"git://github.com/ministryofjustice/advocate-defence-payments.git","ssh_url":"git@github.com:ministryofjustice/advocate-defence-payments.git","clone_url":"https://github.com/ministryofjustice/advocate-defence-payments.git","svn_url":"https://github.com/ministryofjustice/advocate-defence-payments","homepage":"","size":12724,"stargazers_count":3,"watchers_count":3,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":18,"forks":2,"open_issues":18,"watchers":3,"default_branch":"develop"}},"base":{"label":"ministryofjustice:develop","ref":"develop","sha":"615b451b86566085352c11a0fdb9e89c9a80c9a9","user":{"login":"ministryofjustice","id":2203574,"avatar_url":"https://avatars.githubusercontent.com/u/2203574?v=3","gravatar_id":"","url":"https://api.github.com/users/ministryofjustice","html_url":"https://github.com/ministryofjustice","followers_url":"https://api.github.com/users/ministryofjustice/followers","following_url":"https://api.github.com/users/ministryofjustice/following{/other_user}","gists_url":"https://api.github.com/users/ministryofjustice/gists{/gist_id}","starred_url":"https://api.github.com/users/ministryofjustice/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ministryofjustice/subscriptions","organizations_url":"https://api.github.com/users/ministryofjustice/orgs","repos_url":"https://api.github.com/users/ministryofjustice/repos","events_url":"https://api.github.com/users/ministryofjustice/events{/privacy}","received_events_url":"https://api.github.com/users/ministryofjustice/received_events","type":"Organization","site_admin":false},"repo":{"id":32451549,"name":"advocate-defence-payments","full_name":"ministryofjustice/advocate-defence-payments","owner":{"login":"ministryofjustice","id":2203574,"avatar_url":"https://avatars.githubusercontent.com/u/2203574?v=3","gravatar_id":"","url":"https://api.github.com/users/ministryofjustice","html_url":"https://github.com/ministryofjustice","followers_url":"https://api.github.com/users/ministryofjustice/followers","following_url":"https://api.github.com/users/ministryofjustice/following{/other_user}","gists_url":"https://api.github.com/users/ministryofjustice/gists{/gist_id}","starred_url":"https://api.github.com/users/ministryofjustice/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ministryofjustice/subscriptions","organizations_url":"https://api.github.com/users/ministryofjustice/orgs","repos_url":"https://api.github.com/users/ministryofjustice/repos","events_url":"https://api.github.com/users/ministryofjustice/events{/privacy}","received_events_url":"https://api.github.com/users/ministryofjustice/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ministryofjustice/advocate-defence-payments","description":"Claim for crown court defence","fork":false,"url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments","forks_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/forks","keys_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/teams","hooks_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/hooks","issue_events_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/issues/events{/number}","events_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/events","assignees_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/assignees{/user}","branches_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/branches{/branch}","tags_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/tags","blobs_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/git/refs{/sha}","trees_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/statuses/{sha}","languages_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/languages","stargazers_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/stargazers","contributors_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/contributors","subscribers_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/subscribers","subscription_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/subscription","commits_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/commits{/sha}","git_commits_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/git/commits{/sha}","comments_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/comments{/number}","issue_comment_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/issues/comments{/number}","contents_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/contents/{+path}","compare_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/merges","archive_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/downloads","issues_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/issues{/number}","pulls_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls{/number}","milestones_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/milestones{/number}","notifications_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/labels{/name}","releases_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/releases{/id}","deployments_url":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/deployments","created_at":"2015-03-18T10:10:18Z","updated_at":"2016-03-17T13:20:38Z","pushed_at":"2016-05-26T10:18:19Z","git_url":"git://github.com/ministryofjustice/advocate-defence-payments.git","ssh_url":"git@github.com:ministryofjustice/advocate-defence-payments.git","clone_url":"https://github.com/ministryofjustice/advocate-defence-payments.git","svn_url":"https://github.com/ministryofjustice/advocate-defence-payments","homepage":"","size":12724,"stargazers_count":3,"watchers_count":3,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":18,"forks":2,"open_issues":18,"watchers":3,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/1465"},"html":{"href":"https://github.com/ministryofjustice/advocate-defence-payments/pull/1465"},"issue":{"href":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/issues/1465"},"comments":{"href":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/issues/1465/comments"},"review_comments":{"href":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/1465/comments"},"review_comment":{"href":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/pulls/1465/commits"},"statuses":{"href":"https://api.github.com/repos/ministryofjustice/advocate-defence-payments/statuses/2fede14397fec8aca398359dae8d4c6fdfde8f0c"}}}}
{"actor":{"display_login":"slorek"}}