Skip to content

Commit

Permalink
multi: Cleanup superfluous leading newlines.
Browse files Browse the repository at this point in the history
  • Loading branch information
davecgh authored and jholdstock committed Sep 14, 2023
1 parent f2867ac commit a73377b
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 6 deletions.
2 changes: 0 additions & 2 deletions internal/gui/account.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ type accountPageData struct {
// a valid address with associated account information is provided,
// otherwise renders the index template with an appropriate error message.
func (ui *GUI) account(w http.ResponseWriter, r *http.Request) {

address := r.FormValue("address")
if address == "" {
ui.renderIndex(w, r, "No address provided")
Expand Down Expand Up @@ -88,7 +87,6 @@ func (ui *GUI) account(w http.ResponseWriter, r *http.Request) {
// address has an account on the server a "200 OK" response is returned,
// otherwise a "400 Bad Request" or "404 Not Found" are returned.
func (ui *GUI) isPoolAccount(w http.ResponseWriter, r *http.Request) {

address := r.FormValue("address")

// Generate the account ID of the provided address.
Expand Down
1 change: 0 additions & 1 deletion pool/pool_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ func teardownBoltDB(db *BoltDB, dbPath string) error {

// TestPool runs all pool related tests which require a real database.
func TestPool(t *testing.T) {

// All sub-tests to run. All of these tests will be run with a postgres
// database and a bolt database.
tests := map[string]func(*testing.T){
Expand Down
3 changes: 0 additions & 3 deletions pool/postgres.go
Original file line number Diff line number Diff line change
Expand Up @@ -840,7 +840,6 @@ func (db *PostgresDB) persistAcceptedWork(work *AcceptedWork) error {
_, err := db.DB.Exec(insertAcceptedWork, work.UUID, work.BlockHash, work.PrevHash,
work.Height, work.MinedBy, work.Miner, work.CreatedOn, work.Confirmed)
if err != nil {

var pqError *pq.Error
if errors.As(err, &pqError) {
if pqError.Code.Name() == "unique_violation" {
Expand Down Expand Up @@ -951,7 +950,6 @@ func (db *PostgresDB) persistJob(job *Job) error {

_, err := db.DB.Exec(insertJob, job.UUID, job.Height, job.Header)
if err != nil {

var pqError *pq.Error
if errors.As(err, &pqError) {
if pqError.Code.Name() == "unique_violation" {
Expand Down Expand Up @@ -1000,7 +998,6 @@ func (db *PostgresDB) persistHashData(hashData *HashData) error {
hashData.Miner, hashData.IP, hashData.HashRate.RatString(),
hashData.UpdatedOn)
if err != nil {

var pqError *pq.Error
if errors.As(err, &pqError) {
if pqError.Code.Name() == "unique_violation" {
Expand Down

0 comments on commit a73377b

Please sign in to comment.