Unable in install and load packages after R and R studio update

So I just updated R and R studio on my computer, and now I can install the tidyverse or load other packages. I get the errors shown below

> install.packages("tidyverse")
Warning in install.packages :
  unable to access index for repository https://cran.rstudio.com/src/contrib:
  cannot open URL 'https://cran.rstudio.com/src/contrib/PACKAGES'
WARNING: Rtools is required to build R packages but is not currently installed. Please download and install the appropriate version of Rtools before proceeding:

https://cran.rstudio.com/bin/windows/Rtools/
Warning in install.packages :
  unable to access index for repository https://cran.rstudio.com/src/contrib:
  cannot open URL 'https://cran.rstudio.com/src/contrib/PACKAGES'
Warning in install.packages :
  package ‘tidyverse’ is not available for this version of R

A version of this package for your version of R might be available elsewhere,
see the ideas at
https://cran.r-project.org/doc/manuals/r-patched/R-admin.html#Installing-packages
Warning in install.packages :
  unable to access index for repository https://cran.rstudio.com/bin/windows/contrib/4.2:
  cannot open URL 'https://cran.rstudio.com/bin/windows/contrib/4.2/PACKAGES'
> library(tidyverse)
Error in library(tidyverse) : there is no package called ‘tidyverse’
> library(ggplot2)
Error in library(ggplot2) : there is no package called ‘ggplot2’
Warning: unable to access index for repository https://cran.rstudio.com/src/contrib:
  cannot open URL 'https://cran.rstudio.com/src/contrib/PACKAGES'
> install.packages(ggplot2)
Error in install.packages : object 'ggplot2' not found
> library(ggplot)
Error in library(ggplot) : there is no package called ‘ggplot’
> 

Everything was working fine yesterday before I did the update, so I'm pretty sure my code isn't an issue. Do I have to clear anything or something to get it to work? I've tried restarting R and my computer and these don't seem to help

unable to access index for repository https://cran.rstudio.com/src/contrib:

This is most likely a temporary connectivity problem between your site and the host.