Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Examples/Google/SpeechToText/Sources/ViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ final class ViewController: UIViewController {
}
}

private var audioData: Data = Data()
private var audioData = Data()

private let speechService: SpeechService
private let audioStreamManager: AudioStreamManager
Expand Down Expand Up @@ -159,7 +159,7 @@ extension ViewController: StreamDelegate {
self.audioData.append(data)

// 100 ms chunk size
let chunkSize: Int = Int(0.1 * Constants.sampleRate * 2)
let chunkSize = Int(0.1 * Constants.sampleRate * 2)

// When the audio data gets big enough
if self.audioData.count > chunkSize {
Expand Down
2 changes: 1 addition & 1 deletion Sources/GRPC/GRPCKeepaliveHandlers.swift
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ struct PingHandler {
/// Number of active streams
private var activeStreams = 0 {
didSet {
if activeStreams > 0 {
if self.activeStreams > 0 {
self.sentPingsWithoutData = 0
}
}
Expand Down
2 changes: 1 addition & 1 deletion Sources/GRPC/GRPCTimeout.swift
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import NIO
/// Timeouts must be positive and at most 8-digits long.
public struct GRPCTimeout: CustomStringConvertible, Equatable {
/// Creates an infinite timeout. This is a sentinel value which must __not__ be sent to a gRPC service.
public static let infinite: GRPCTimeout = GRPCTimeout(
public static let infinite = GRPCTimeout(
nanoseconds: Int64.max,
wireEncoding: "infinite"
)
Expand Down
2 changes: 1 addition & 1 deletion Sources/GRPC/ServerCallContexts/ServerCallContext.swift
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ open class ServerCallContextBase: ServerCallContext {

/// Metadata to return at the end of the RPC. If this is required it should be updated before
/// the `responsePromise` or `statusPromise` is fulfilled.
public var trailingMetadata: HTTPHeaders = HTTPHeaders()
public var trailingMetadata = HTTPHeaders()

public init(eventLoop: EventLoop, request: HTTPRequestHead, logger: Logger) {
self.eventLoop = eventLoop
Expand Down