Skip to content
Snippets Groups Projects
Commit aa4736e4 authored by Xavier Robin's avatar Xavier Robin
Browse files

fix: pdb author resnum/insertion code in atom_sites

parent 9825e096
Branches
Tags
No related merge requests found
...@@ -1012,15 +1012,11 @@ namespace { ...@@ -1012,15 +1012,11 @@ namespace {
} }
String auth_seq_id = res.GetNumber().AsString(); String auth_seq_id = res.GetNumber().AsString();
if(res.HasProp("pdb_auth_resnum")) { if(res.HasProp("pdb_auth_resnum")) {
std::stringstream ss; auth_seq_id = res.GetStringProp("pdb_auth_resnum");
ss << res.GetStringProp("pdb_auth_resnum"); }
if(res.HasProp("pdb_auth_ins_code")) { String ins_code = "";
String ins_code = res.GetStringProp("pdb_auth_ins_code"); if(res.HasProp("pdb_auth_ins_code")) {
if(ins_code != "?") { ins_code = res.GetStringProp("pdb_auth_ins_code");
ss << ins_code;
}
}
auth_seq_id = ss.str();
} }
if(entity_info.is_poly) { if(entity_info.is_poly) {
...@@ -1075,7 +1071,7 @@ namespace { ...@@ -1075,7 +1071,7 @@ namespace {
// id // id
at_data.push_back(ost::io::StarWriterLoopDataItem(atom_site_ptr->GetN())); at_data.push_back(ost::io::StarWriterLoopDataItem(atom_site_ptr->GetN()));
// pdbx_PDB_ins_code // pdbx_PDB_ins_code
at_data.push_back(ost::io::StarWriterLoopDataItem("")); // CHECK THIS, ADD STUFF FROM AUTH_SEQ_ID? at_data.push_back(ost::io::StarWriterLoopDataItem(ins_code));
atom_site_ptr->AddData(at_data); atom_site_ptr->AddData(at_data);
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment