Fix linting issues

This commit is contained in:
Lena Fuhrimann 2018-06-18 20:39:58 +02:00
parent b3ed71e623
commit def33c3314
5 changed files with 17 additions and 17 deletions

12
Gopkg.lock generated
View file

@ -17,13 +17,13 @@
branch = "master"
name = "github.com/mastertinner/adapters"
packages = ["logging"]
revision = "368acae73d1569f0495b00991aaa85ec27d6ee8e"
revision = "9704a6fb93c903ec6e38a8420cc82d3a95668966"
[[projects]]
name = "github.com/matryer/is"
packages = ["."]
revision = "9c9f59466947e14647c98703d408d5d6d985648d"
version = "v1.0.0"
revision = "5f0030ca4decdf2e702be47575d88eabf610593e"
version = "v1.1.0"
[[projects]]
branch = "master"
@ -70,7 +70,7 @@
"blake2b",
"ssh/terminal"
]
revision = "027cca12c2d63e3d62b670d901e8a2c95854feec"
revision = "7f39a6fea4fe9364fb61e1def6a268a51b4f3a06"
[[projects]]
branch = "master"
@ -89,7 +89,7 @@
"unix",
"windows"
]
revision = "6c888cc515d3ed83fc103cf1d84468aad274b0a7"
revision = "ad87a3a340fa7f3bed189293fbfa7a9b7e021ae1"
[[projects]]
name = "golang.org/x/text"
@ -115,6 +115,6 @@
[solve-meta]
analyzer-name = "dep"
analyzer-version = 1
inputs-digest = "23bebd60feeb7a8199093dfad639c43cea63091672e649b80203796f7117997c"
inputs-digest = "f26310f695dd83254e86dc025480d98772b0a1055f11a1b2728bead0e869c8f0"
solver-name = "gps-cdcl"
solver-version = 1

View file

@ -31,7 +31,7 @@
[[constraint]]
name = "github.com/matryer/is"
version = "1.0.0"
version = "1.1.0"
[[constraint]]
branch = "master"

View file

@ -14,7 +14,7 @@ import (
// HandleBucketView shows the details page of a bucket.
func HandleBucketView(s3 S3, tmplDir string) http.HandlerFunc {
type objectWithIcon struct {
minio.ObjectInfo
Info minio.ObjectInfo
Icon string
}
@ -34,7 +34,7 @@ func HandleBucketView(s3 S3, tmplDir string) http.HandlerFunc {
handleHTTPError(w, errors.Wrap(object.Err, "error listing objects"))
return
}
obj := objectWithIcon{object, icon(object.Key)}
obj := objectWithIcon{Info: object, Icon: icon(object.Key)}
objs = append(objs, obj)
}
data := pageData{

View file

@ -29,10 +29,10 @@
{{ range $index, $object := .Objects }}
<tr>
<td style="padding-left: 25px;"><i class="material-icons">{{ $object.Icon }}</i></td>
<td>{{ $object.Key }}</td>
<td>{{ $object.Size }} bytes</td>
<td>{{ $object.Owner }}</td>
<td>{{ $object.LastModified }}</td>
<td>{{ $object.Info.Key }}</td>
<td>{{ $object.Info.Size }} bytes</td>
<td>{{ $object.Info.Owner }}</td>
<td>{{ $object.Info.LastModified }}</td>
<td>
<!-- Dropdown Trigger -->
<a class="dropdown-button waves-effect waves-teal btn-flat" href="#" data-activates="actions-dropdown-{{ $index }}">
@ -41,8 +41,8 @@
<!-- Dropdown Structure -->
<ul id="actions-dropdown-{{ $index }}" class="dropdown-content">
<li><a href="/api/buckets/{{ $.BucketName }}/objects/{{ $object.Key }}">Download</a></li>
<li><a href="#" onclick="deleteObject({{ $.BucketName }}, {{ $object.Key }})">Delete</a></li>
<li><a href="/api/buckets/{{ $.BucketName }}/objects/{{ $object.Info.Key }}">Download</a></li>
<li><a href="#" onclick="deleteObject({{ $.BucketName }}, {{ $object.Info.Key }})">Delete</a></li>
</ul>
</td>
</tr>

View file

@ -10,7 +10,7 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0-beta/css/materialize.min.css"><Paste>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0-rc.1/css/materialize.min.css" integrity="sha256-qj3p6P1fJIV+Ndv7RW1ovZI2UhOuboj9GcODzcNFIN8=" crossorigin="anonymous" />
</head>
<body>
@ -22,7 +22,7 @@
integrity="sha256-FgpCb/KJQlLNfOu91ta32o/NMZxltwRo8QtmkMRdAu8="
crossorigin="anonymous"
></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0-beta/js/materialize.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0-rc.1/js/materialize.min.js" integrity="sha256-SrBfGi+Zp2LhAvy9M1bWOCXztRU9Ztztxmu5BcYPcPE=" crossorigin="anonymous"></script>
<script>
$(document).ready(function(){
$('.modal').modal();