Skip to content

Commit

Permalink
master to main (#11)
Browse files Browse the repository at this point in the history
* move master to main

* fix some linters errors
  • Loading branch information
leandro-lugaresi authored Jul 24, 2020
1 parent 5d3f102 commit 3a69f30
Show file tree
Hide file tree
Showing 8 changed files with 47 additions and 48 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,4 +55,4 @@ Which runs all the linters and tests.
## Submit a pull request

Push your branch to your `example` fork and open a pull request against the
master branch.
main branch.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
[![Release](https://img.shields.io/github/release/leandro-lugaresi/hub.svg?style=flat-square)](https://github.com/leandro-lugaresi/hub/releases/latest)
[![Software License](https://img.shields.io/github/license/leandro-lugaresi/hub.svg?style=flat-square)](LICENSE.md)
[![Actions Status](https://github.com/leandro-lugaresi/hub/workflows/Go/badge.svg)](https://github.com/leandro-lugaresi/hub/actions)
[![Coverage Status](https://img.shields.io/codecov/c/github/leandro-lugaresi/hub/master.svg?style=flat-square)](https://codecov.io/gh/leandro-lugaresi/hub)
[![Coverage Status](https://img.shields.io/codecov/c/github/leandro-lugaresi/hub/main.svg?style=flat-square)](https://codecov.io/gh/leandro-lugaresi/hub)
[![Go Doc](https://img.shields.io/badge/godoc-reference-blue.svg?style=flat-square)](http://godoc.org/github.com/leandro-lugaresi/hub)
[![Go Report Card](https://goreportcard.com/badge/github.com/leandro-lugaresi/hub?style=flat-square)](https://goreportcard.com/report/github.com/leandro-lugaresi/hub)
[![Say Thanks!](https://img.shields.io/badge/Say%20Thanks-!-1EAEDB.svg)](https://saythanks.io/to/leandro-lugaresi)
Expand Down
1 change: 0 additions & 1 deletion hub_benchmark_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ func processSubscriptionsForBench(subs []Subscription, wg *sync.WaitGroup) {
for _, sub := range subs {
go func(s Subscription) {
for range s.Receiver {

}

wg.Done()
Expand Down
20 changes: 10 additions & 10 deletions matching.go
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
//Copyright (C) 2018 Tyler Treat <https://github.com/tylertreat>
//Licensed under the Apache License, Version 2.0 (the "License");
//you may not use this file except in compliance with the License.
//You may obtain a copy of the License at
// Copyright (C) 2018 Tyler Treat <https://github.com/tylertreat>
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at

// http://www.apache.org/licenses/LICENSE-2.0

//Unless required by applicable law or agreed to in writing, software
//distributed under the License is distributed on an "AS IS" BASIS,
//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//See the License for the specific language governing permissions and
//limitations under the License.
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

//Modifications copyright (C) 2018 Leandro Lugaresi
// Modifications copyright (C) 2018 Leandro Lugaresi

package hub

Expand Down
22 changes: 11 additions & 11 deletions matching_cstrie.go
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
//Copyright (C) 2018 Tyler Treat <https://github.com/tylertreat>
//Licensed under the Apache License, Version 2.0 (the "License");
//you may not use this file except in compliance with the License.
//You may obtain a copy of the License at
// Copyright (C) 2018 Tyler Treat <https://github.com/tylertreat>
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at

// http://www.apache.org/licenses/LICENSE-2.0

//Unless required by applicable law or agreed to in writing, software
//distributed under the License is distributed on an "AS IS" BASIS,
//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//See the License for the specific language governing permissions and
//limitations under the License.
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

//Modifications copyright (C) 2018 Leandro Lugaresi
// Modifications copyright (C) 2018 Leandro Lugaresi

package hub

Expand Down Expand Up @@ -430,7 +430,7 @@ func (c *csTrieMatcher) bLookup(i *iNode, b *branch, words []string) ([]subscrib
return b.subscribers(), true
}

// Subscriptions return all the subscriptions inside the cstrie
// Subscriptions return all the subscriptions inside the cstrie.
func (c *csTrieMatcher) Subscriptions() []Subscription {
var (
rootPtr = (*unsafe.Pointer)(unsafe.Pointer(&c.root))
Expand Down
20 changes: 10 additions & 10 deletions matching_cstrie_test.go
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
//Copyright (C) 2018 Tyler Treat <https://github.com/tylertreat>
//Licensed under the Apache License, Version 2.0 (the "License");
//you may not use this file except in compliance with the License.
//You may obtain a copy of the License at
// Copyright (C) 2018 Tyler Treat <https://github.com/tylertreat>
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at

// http://www.apache.org/licenses/LICENSE-2.0

//Unless required by applicable law or agreed to in writing, software
//distributed under the License is distributed on an "AS IS" BASIS,
//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//See the License for the specific language governing permissions and
//limitations under the License.
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

//Modifications copyright (C) 2018 Leandro Lugaresi
// Modifications copyright (C) 2018 Leandro Lugaresi

package hub

Expand Down
8 changes: 4 additions & 4 deletions subscriber.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ func (s *nonBlockingSubscriber) Ch() <-chan Message {
return s.ch
}

// Close will close the internal channel and stop receiving messages
// Close will close the internal channel and stop receiving messages.
func (s *nonBlockingSubscriber) Close() {
s.onceClose.Do(func() {
close(s.ch)
Expand All @@ -65,17 +65,17 @@ func newBlockingSubscriber(cap int) *blockingSubscriber {
}
}

// Set will send the message using the channel
// Set will send the message using the channel.
func (s *blockingSubscriber) Set(msg Message) {
s.ch <- msg
}

// Ch return the channel used by subscriptions to consume messages
// Ch return the channel used by subscriptions to consume messages.
func (s *blockingSubscriber) Ch() <-chan Message {
return s.ch
}

// Close will close the internal channel and stop receiving messages
// Close will close the internal channel and stop receiving messages.
func (s *blockingSubscriber) Close() {
s.onceClose.Do(func() {
close(s.ch)
Expand Down
20 changes: 10 additions & 10 deletions utils_test.go
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
//Copyright (C) 2018 Tyler Treat <https://github.com/tylertreat>
//Licensed under the Apache License, Version 2.0 (the "License");
//you may not use this file except in compliance with the License.
//You may obtain a copy of the License at
// Copyright (C) 2018 Tyler Treat <https://github.com/tylertreat>
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at

// http://www.apache.org/licenses/LICENSE-2.0

//Unless required by applicable law or agreed to in writing, software
//distributed under the License is distributed on an "AS IS" BASIS,
//WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//See the License for the specific language governing permissions and
//limitations under the License.
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

//Modifications copyright (C) 2018 Leandro Lugaresi
// Modifications copyright (C) 2018 Leandro Lugaresi

package hub

Expand Down

0 comments on commit 3a69f30

Please sign in to comment.