From afea33981b5ba8bba3aa31e52feaf1299a712cad Mon Sep 17 00:00:00 2001
From: Casey Kuhlman <casey@erisindustries.com>
Date: Fri, 10 Jun 2016 18:52:40 +0200
Subject: [PATCH] finalize the right padding of permissions for other roles
 funcs

---
 .../tendermint/tendermint/permission/types/permissions.go     | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/Godeps/_workspace/src/github.com/tendermint/tendermint/permission/types/permissions.go b/Godeps/_workspace/src/github.com/tendermint/tendermint/permission/types/permissions.go
index fed65416..456a494a 100644
--- a/Godeps/_workspace/src/github.com/tendermint/tendermint/permission/types/permissions.go
+++ b/Godeps/_workspace/src/github.com/tendermint/tendermint/permission/types/permissions.go
@@ -124,7 +124,7 @@ type AccountPermissions struct {
 
 // Returns true if the role is found
 func (aP *AccountPermissions) HasRole(role string) bool {
-	role = string(LeftPadBytes([]byte(role), 32))
+	role = string(RightPadBytes([]byte(role), 32))
 	for _, r := range aP.Roles {
 		if r == role {
 			return true
@@ -147,7 +147,7 @@ func (aP *AccountPermissions) AddRole(role string) bool {
 
 // Returns true if the role is removed, and false if it is not found
 func (aP *AccountPermissions) RmRole(role string) bool {
-	role = string(LeftPadBytes([]byte(role), 32))
+	role = string(RightPadBytes([]byte(role), 32))
 	for i, r := range aP.Roles {
 		if r == role {
 			post := []string{}
-- 
GitLab