[RELEASE] Merge BETA into MASTER by rafaelks · Pull Request #2697 · RocketChat/Rocket.Chat.iOS · GitHub
Skip to content
This repository was archived by the owner on Jun 7, 2020. It is now read-only.

[RELEASE] Merge BETA into MASTER#2697

Merged
rafaelks merged 68 commits into
masterfrom
beta
May 10, 2019
Merged

[RELEASE] Merge BETA into MASTER#2697
rafaelks merged 68 commits into
masterfrom
beta

Conversation

@rafaelks

Copy link
Copy Markdown
Contributor

@RocketChat/ios

rafaelks and others added 30 commits February 11, 2019 10:42
We can remove the else-if-condition where we are checking for the original image. This is because whenever the user selects an image for their avatar from the photo library, the cropping tool is always called. So, there will always be an .editedImage.
[NEW] Crop image before uploading avatar
…tes_support

[NEW] SSL client certificates support (two-way authentication)
[IMPROVEMENT] Swipe to read messages with uniform colour
rafaelks and others added 24 commits April 30, 2019 10:58
[FIX] Prevent CustomEmoji image URL double url escaping
[CHORE] Upgrade project to latest Xcode & Swift 5
Revert "[CHORE] Upgrade project to latest Xcode & Swift 5"
… the flow, add docs links, fixed theming in some parts of the app and more
[RELEASE] Merge DEVELOP into BETA
[IMPROVEMENT] Adjustments on Threads implementation
[RELEASE] Merge DEVELOP into BETA
@rafaelks rafaelks added this to the 3.5.0 milestone May 10, 2019

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Superfluous Disable Command Violation: SwiftLint rule 'cyclomatic_complexity' did not trigger a violation in the disabled region. Please remove the disable command. (superfluous_disable_command)

extension ThreadsViewController: ChatMessageCellProtocol {

func openThread(identifier: String) {
guard let controller = UIStoryboard.controller(from: "Chat", identifier: "Chat") as? MessagesViewController else {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line Length Violation: Line should be 120 characters or less: currently 122 characters (line_length)

return .zero
}

func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, sizeForItemAt indexPath: IndexPath) -> CGSize {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line Length Violation: Line should be 120 characters or less: currently 160 characters (line_length)

return 0
}

func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, insetForSectionAt section: Int) -> UIEdgeInsets {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line Length Violation: Line should be 120 characters or less: currently 162 characters (line_length)

return 0
}

func collectionView(_ collectionView: UICollectionView, layout collectionViewLayout: UICollectionViewLayout, minimumInteritemSpacingForSectionAt section: Int) -> CGFloat {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line Length Violation: Line should be 120 characters or less: currently 175 characters (line_length)

let threadIdentifier: String?

init(id: String, roomId: String, text: String, messageType: String? = nil) {
init(id: String, roomId: String, text: String, threadIdentifier: String? = nil, messageType: String? = nil) {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Identifier Name Violation: Variable name should be between 3 and 40 characters long: 'id' (identifier_name)

internalType: String? = nil,
subscription: UnmanagedSubscription,
threadIdentifier: String? = nil,
id: String = String.random(18),

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Identifier Name Violation: Variable name should be between 3 and 40 characters long: 'id' (identifier_name)

return self.characters.count
}
}
#endif

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

File Line Length Violation: File should contain 400 lines or less: currently contains 1356 (file_length)

self.advancedDelegate?.websocketDidDisconnect(socket: self, error: error)
let userInfo = error.map{ [WebsocketDisconnectionErrorKeyName: $0] }
s.notificationCenter.post(name: NSNotification.Name(WebsocketDidDisconnectNotification), object: self, userInfo: userInfo)
NotificationCenter.default.post(name: NSNotification.Name(WebsocketDidDisconnectNotification), object: self, userInfo: userInfo)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line Length Violation: Line should be 120 characters or less: currently 140 characters (line_length)

s.doDisconnect(error as NSError?)
let len = stream.write(data: Data(bytes: writeBuffer, count: offset-total))
if len <= 0 {
self.doDisconnect(WSError(type: .outputStreamWriteError, message: "output stream had an error during write", code: 0))

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line Length Violation: Line should be 120 characters or less: currently 138 characters (line_length)

XCTAssertEqual(request.value(forHTTPHeaderField: "Content-Type"), "application/json", "content type is correct")
}

func testProperties() {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function Body Length Violation: Function body should span 40 lines or less excluding comments and whitespace: currently spans 47 lines (function_body_length)

}

}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Trailing Newline Violation: Files should have a single trailing newline. (trailing_newline)

XCTAssertEqual(request.httpMethod, "GET", "http method is correct")
}

func testProperties() {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function Body Length Violation: Function body should span 40 lines or less excluding comments and whitespace: currently spans 42 lines (function_body_length)

// MARK: Connection

static func connect(_ url: URL, completion: @escaping SocketCompletion) {
static func connect(_ url: URL, sslCertificate: SSLClientCertificate? = nil, completion: @escaping SocketCompletion) {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line Length Violation: Line should be 120 characters or less: currently 122 characters (line_length)

- oldestMessage: This is the parameter that will be sent to the server in
order to get the correct page of data.
*/
// swiftlint:disable function_body_length cyclomatic_complexity

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Superfluous Disable Command Violation: SwiftLint rule 'cyclomatic_complexity' did not trigger a violation in the disabled region. Please remove the disable command. (superfluous_disable_command)

}

func openThread(identifier: String) {
guard let controller = UIStoryboard.controller(from: "Chat", identifier: "Chat") as? MessagesViewController else {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line Length Violation: Line should be 120 characters or less: currently 122 characters (line_length)

var isCompressedReplyLayout = true

init(object: AnyDifferentiable, controllerContext: UIViewController?, collapsibleItemsState: [AnyHashable: Bool]) {
init(object: AnyDifferentiable, controllerContext: UIViewController?, collapsibleItemsState: [AnyHashable: Bool], inverted: Bool = true, compressedLayout: Bool = true) {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line Length Violation: Line should be 120 characters or less: currently 173 characters (line_length)

api.sslCertificatePassword = self?.certificateFilePassword ?? ""
}

api.client(InfoClient.self).fetchLoginServices(completion: { loginServices, shouldRetrieveLoginServices in

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line Length Violation: Line should be 120 characters or less: currently 126 characters (line_length)


@IBAction func buttonCertificateDidPressed(_ sender: Any) {
if let url = certificateFileURL {
let alert = UIAlertController(title: url.pathComponents.last ?? "", message: nil, preferredStyle: .actionSheet)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Line Length Violation: Line should be 120 characters or less: currently 123 characters (line_length)

let threadIdentifier: String?

init(id: String, roomId: String, text: String, messageType: String? = nil) {
init(id: String, roomId: String, text: String, threadIdentifier: String? = nil, messageType: String? = nil) {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Identifier Name Violation: Variable name should be between 3 and 40 characters long: 'id' (identifier_name)

@codecov

codecov Bot commented May 10, 2019

Copy link
Copy Markdown

Codecov Report

❗ No coverage uploaded for pull request base (master@df0e867). Click here to learn what that means.
The diff coverage is 20.09%.

Impacted file tree graph

@@            Coverage Diff            @@
##             master    #2697   +/-   ##
=========================================
  Coverage          ?   25.38%           
=========================================
  Files             ?      478           
  Lines             ?    18070           
  Branches          ?        0           
=========================================
  Hits              ?     4587           
  Misses            ?    13483           
  Partials          ?        0
Impacted Files Coverage Δ
...ws/Chat/New Chat/Cells/MessageDiscussionCell.swift 0% <ø> (ø)
...at/Views/Cells/Subscription/SubscriptionCell.swift 0% <ø> (ø)
Rocket.Chat/Models/Message/Message.swift 88.57% <ø> (ø)
...et.Chat/Views/Directory/DirectoryFiltersView.swift 0% <ø> (ø)
Rocket.Chat/Theme/ThemeableViews.swift 43.13% <ø> (ø)
...ket.Chat/Views/Subscriptions/ServersListView.swift 0% <ø> (ø)
Rocket.Chat/Models/Message/MessageReply.swift 80% <ø> (ø)
Rocket.Chat/Views/Cells/Chat/ChatMessageCell.swift 0% <ø> (ø)
...Views/Subscriptions/SubscriptionsSortingView.swift 0% <ø> (ø)
...at/MessagesViewControllerMessageCellProtocol.swift 0% <ø> (ø)
... and 49 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update df0e867...ff91589. Read the comment docs.

@rafaelks rafaelks merged commit c603adc into master May 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants