G Suite Horror Story

Yesterday my life long Gmail account has been deleted by Google because I integrated it with G Suite by cancelling the subscription.

G Suite for business was a mean to upgrade your personal email so that all your inbox will be unified. But the more email gets into the inbox, the more cluttered it seems. It was hard to manage.

Then, I searched for any way to break apart my personal Gmail from my G Suite account. It was complicated. This is not my first time using G Suite, previous account I just cancelled and move on with my personal Gmail. So I cancelled my subscription. And after that I can’t access my personal Gmail. Things starting to turn for the worse.

I searched for solutions, it turned out I had “unlock” some features that I upgraded my personal account into a business account and there was no coming back. I had setup that G Suite months ago and I can’t remember any “unlock” features prompting me.

As I kept digging Google’s Help Forums, it turns out I am not the only one in this predicament. Below are examples. Take notice on Google’s Customer Support’s passive solutions.

Canceled my G suite account and my @gmail.com is no longer working

Another one, I cancelled g-suite trial but now can’t access my email. In that thread, Google’s Customer Support replied with

If you cancel and delete Gsuite this will have no effects on your personal Gmail account there is not no way to restore a deleted the Gsuite account

So you just need sign into your personal Gmail account.to access your mail and contacts

Whew! That was reassuring. But when you login back to your Gmail account, me and this user has the same problem. It will display a server error

Server error

Sorry, you’ve reached a login page for a domain that isn’t using G Suite. Please check the web address and try again.

Shit. My Gmail account is using G Suite. I opened a ticket to Google’s Help Forum. Cancel GSuite subscription and now cannot login

So, the thing is I setup a business email powered by G Suite instead of another G Suite? Confusing. Their setup and landing page looks the same. Anyway, I looked into their Cancel your business email documentation and it mentioned

After you cancel, you can no longer send or receive mail from your business email address (for example, you@yourcompany.com); you return to using free, basic Gmail.

You return using free, basic Gmail. But how come I can’t access my personal Gmail account anymore? I’ve used that email for over 8 years, all my history is gone. All the Google Drive files, the Google Docs and Sheets of important data and documents.

To anyone using Business G Suite just make sure that you’ve “downgrade” instead of cancelling your subscription. This is very sad on my part, a hard lesson to learn. I should have read carefully the details. To Google, I lost trust in your service.

This post went viral on Hacker News back in 2018.

Implementing the expandable cell in iOS UITableView

I’m going to implement below on how to create the expandable UITableView cell for example on iOS stock calendar.

1-K0Xsn4n9Lx2lqpUDNO-xXA

From scratch, create a new project on Xcode. In your main.storyboard remove the default ViewController (delete also the extra unused ViewController.swift file in the project explorer) and drag a new TableViewController.

1-ti0Kq9gWuhSdxOPXvRjDDw

Now that we have our TableViewController set on the storyboard. Let’s create a new Swift file, and call it for example FormTableViewController.swift. And set is as the custom class in your TableViewController.

1-XPDBMIMfwL7hBdvehkUnjQ
1-366I_Aw3939Z5uXtdVX0fg

Now we are all set. We are gonna change the TableView’s Content from Dynamic Prototypes to Static Cells.

After setting it to Static Cells, your TableView will have a default of 3 static cells created.

For this demo it won’t matter how many cells we are going to use.

The secret to this is the proper measurement of a cell. Click on the first cell and change the row height to 250. Our plan is, inside the cell we will have 2 views. The Label which has a height of 50 and DatePicker with a height of 200. A total of 250. On the storyboard, drag a Label and DatePicker on the first cell, setup its constraints and embed our TableViewController with a NavigationController, it should look like the image below.

1-VOvLjMRH2f8Gyu7LmfFvYA

Now let’s start coding. Inside your FormTableViewController you need to override two functions, namely TableView’s didSelectRowAt and heightForRowAt.

import UIKit

class FormTableViewController: UITableViewController {

    private var dateCellExpanded: Bool = false

    override func viewDidLoad() {
        super.viewDidLoad()
        // For removing the extra empty spaces of TableView below
        tableView.tableFooterView = UIView()
    }

    override func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
        if indexPath.row == 0 {
            if dateCellExpanded {
                dateCellExpanded = false
            } else {
                dateCellExpanded = true
            }
            tableView.beginUpdates()
            tableView.endUpdates()
        }
    }

    override func tableView(_ tableView: UITableView, heightForRowAt indexPath: IndexPath) -> CGFloat {
        if indexPath.row == 0 {
            if dateCellExpanded {
                return 250
            } else {
                return 50
            }
        }
        return 50
    }
}


I’m going to explain shortly about the code. The variable dateCellExpanded is a flag to determine if the current cell selected has been expanded or not. Then, after always call tableView.beginUpdates() and tableView.endUpdates() and it will trigger the delegate function of TableView heightForRowAt to determine what height value should we return or not. Yep, it is that simple. Click RUN!

1-_TMKiaY6yEn4iGw2w_vdvQ

Hopefully this demo should give you an idea on how to implement it on your app.

The example project can be found at https://github.com/lawgimenez/expandable-cell-test