[ox] Remove redundant null check before delete

This commit is contained in:
Gary Talent 2019-02-24 23:52:14 -06:00
parent d3f78982e6
commit 3facd25794
2 changed files with 3 additions and 5 deletions

View File

@ -11,7 +11,7 @@
namespace ox {
FileLocation::~FileLocation() {
if (m_type == Path && m_data.path) {
if (m_type == Path) {
delete m_data.path;
m_data.path = nullptr;
}

View File

@ -99,10 +99,8 @@ Vector<T>::Vector(Vector<T> &&other) noexcept {
template<typename T>
Vector<T>::~Vector() noexcept {
if (m_items) {
delete[] m_items;
m_items = nullptr;
}
delete[] m_items;
m_items = nullptr;
}
template<typename T>